home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 12 / Cream of the Crop 12 (Part II) / Cream of the Crop 12 (Part II).iso / OS2 / TCOS2100.ZIP / TCMDOS2.INF (.txt) < prev    next >
Encoding:
OS/2 Help File  |  1996-03-05  |  402.6 KB  |  12,928 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. About Take Command for OS/2 Help ΓòÉΓòÉΓòÉ
  3.  
  4.                       Take Command for OS/2 1.0 Help System
  5.  
  6.                 Text by Hardin Brothers, Tom Rawson, and Rex Conn
  7.  
  8. Program and Text Copyright 1988 - 1996, JP Software Inc., All Rights Reserved. 
  9.  
  10. Take Command is a registered trademark of JP Software Inc.  OS/2 is a 
  11. registered trademark of IBM Corporation.  Other product and company names are 
  12. trademarks of their respective owners. 
  13.  
  14. [1.0.056 - 2/96] 
  15.  
  16.  
  17. ΓòÉΓòÉΓòÉ 2. Using the Take Command for OS/2 Help System ΓòÉΓòÉΓòÉ
  18.  
  19. This online help system for Take Command for OS/2 covers all Take Command 
  20. features and internal commands.  It includes reference information to assist 
  21. you in using Take Command and developing batch files, and includes most of the 
  22. details which are included in the printed Take Command for OS/2 manuals. 
  23.  
  24. If you type part or all of a command on the line and then press F1, the help 
  25. system will provide "context-sensitive" help by using the first word on the 
  26. line as a help topic.  If it's a valid topic, you will see help for that topic 
  27. automatically; if not, you will see the list of all help topics and you can 
  28. pick the one you want. 
  29.  
  30. You can use this feature to obtain help on any topic -- not just on commands. 
  31. For example, if you enter the command HELP _DISK you will see help for the 
  32. _DISK internal variable. 
  33.  
  34. If you type the name of any internal command at the prompt, followed by a slash 
  35. and a question mark [/?] like this: 
  36.  
  37.         copy /?
  38.  
  39. then you will see help for the command in a "quick-reference" style.  Output 
  40. from a /? display may be redirected with > or >>. 
  41.  
  42. The /? option may not work correctly if you have used an alias to redefine how 
  43. an internal command operates.  To view the /? help for such a command you must 
  44. add an asterisk to the beginning of the command to disable alias processing. 
  45. For example, if you have defined this alias: 
  46.  
  47.         alias copy *copy /r
  48.  
  49. then the command COPY /? will be translated to COPY /R /?, which will not work 
  50. properly (because the /? does not appear immediately after the command name). 
  51. However, if you use *COPY /?, the alias will be ignored and the /? will work as 
  52. you intended. 
  53.  
  54. The Take Command for OS/2 help system uses OS/2's VIEW.EXE to display this help 
  55. text. Once you've started the help system with HELP or F1, you can use VIEW's 
  56. standard keystrokes to navigate.  For more information, click on the Help menu 
  57. at the top of the VIEW window. 
  58.  
  59. Configuring the Help System 
  60.  
  61. For the help system to work properly you must place the files TCMDOS2.INF (this 
  62. help text) and TCMDOS2H.MSG (the "quick-help" text) in the proper directories. 
  63. See File Locations for additional details. 
  64.  
  65. You can select which help "books" are displayed when you press the F1 key or 
  66. enter the HELP command.  A help book is a single .INF file.  This help text is 
  67. in the file TCMDOS2.INF. 
  68.  
  69. By default, Take Command for OS/2 opens only its own help.  You can change the 
  70. default books opened for the Take Command for OS/2 help system with the 
  71. HelpBook directive in TCMDOS2.INI. For example, to load both the Take Command 
  72. for OS/2 help and the OS/2 Command Reference when you press F1 or enter the 
  73. HELP command: 
  74.  
  75.         HelpBook = TCMDOS2+CMDREF
  76.  
  77. (For this statement to work the CMDREF.INF file must be available in a 
  78. directory listed in your BOOKSHELF path in CONFIG.SYS.) 
  79.  
  80.  
  81. ΓòÉΓòÉΓòÉ 3. Take Command Internal Commands ΓòÉΓòÉΓòÉ
  82.  
  83. The best way to learn about commands is to experiment with them.  The lists 
  84. below categorize the available commands by topic and will help you find the 
  85. ones that you need. 
  86.  
  87. System configuration: 
  88.  
  89.     CHCP         CLS          COLOR        DATE
  90.     FREE         HISTORY      KEYS         KEYBD
  91.     LOG          MEMORY       PROMPT       REBOOT
  92.     SETDOS       TIME         VER          VERIFY
  93.     VOL
  94.  
  95. File and directory management: 
  96.  
  97.     ATTRIB       COPY         DEL          DESCRIBE
  98.     FFIND        LIST         MOVE         REN
  99.     SELECT       TYPE
  100.  
  101. Subdirectory management: 
  102.  
  103.     CD           CDD          DIR          DIRS
  104.     MD           POPD         PUSHD        RD
  105.  
  106. Input and output: 
  107.  
  108.     DRAWBOX      DRAWHLINE    DRAWVLINE    ECHO
  109.     ECHOS        INKEY        INPUT        SCREEN
  110.     SCRPUT       TEXT         VSCRPUT
  111.  
  112. Commands primarily for use in or with batch files and aliases (some work only 
  113. in batch files; see the individual commands for details): 
  114.  
  115.     ALIAS        BEEP         CALL         CANCEL
  116.     DELAY        DO           ENDLOCAL     FOR
  117.     GLOBAL       GOSUB        GOTO         IF
  118.     IFF          KEYSTACK     LOADBTM      MSGBOX
  119.     ON           PAUSE        QUERYBOX     QUIT
  120.     REM          RETURN       SETLOCAL     SHIFT
  121.     UNALIAS
  122.  
  123. Environment and path commands: 
  124.  
  125.     DPATH        ESET         PATH         SET
  126.     UNSET
  127.  
  128. Other commands: 
  129.  
  130.     ?            ACTIVATE     DETACH       EXCEPT
  131.     EXIT         HELP         START        SHRALIAS
  132.     TEE          TIMER        WINDOW       Y
  133.     TITLE        WINDOW       Y
  134.  
  135.  
  136. ΓòÉΓòÉΓòÉ 3.1. ? - List internal commands ΓòÉΓòÉΓòÉ
  137.  
  138.  Purpose:    Display a list of internal commands or prompt for a command. 
  139.  
  140.  Format:     ? ["prompt text" command] 
  141.  
  142.  Usage: 
  143.  
  144.  ? by itself displays a list of internal commands . 
  145.  
  146.  If you have disabled a command with SETDOS /I, it will not appear in the list. 
  147.  
  148.  If you add prompt text and a command, ? will display the prompt followed by 
  149.  "(Y/N)?" and wait for the user's response.  If the user presses "Y" or "y", 
  150.  the command will be executed.  If the user presses "N" or "n", the command 
  151.  will be ignored. 
  152.  
  153.           [c:\] ?"Load the network"  call netstart.btm
  154.  
  155.  
  156. ΓòÉΓòÉΓòÉ 3.2. ACTIVATE - Activate or change window state ΓòÉΓòÉΓòÉ
  157.  
  158.  Purpose:    Activate a window, change its state, or change its title. 
  159.  
  160.  Format:     ACTIVATE "window" [MAX | MIN | RESTORE | CLOSE | "title"] 
  161.  
  162.              window :  Current title of window to work with. 
  163.              title : New title for window. 
  164.  
  165.  See also:  START, TITLE, and WINDOW. 
  166.  
  167.  Usage: 
  168.  
  169.  Both the current name of the window and the new name, if any, must be enclosed 
  170.  in double quotes.  The quotes will not appear as part of the title bar text. 
  171.  
  172.  If no options are used, the window named in the command will become the active 
  173.  window and be able to receive keystrokes and mouse commands. 
  174.  
  175.  The MAX option expands the window to its maximum size, the MIN option reduces 
  176.  the window to an icon, and the RESTORE option returns the window to its 
  177.  default size and location on the desktop.  The CLOSE option closes the window 
  178.  and ends the session running in the window. 
  179.  
  180.  This example renames and maximizes the window called "Take Command": 
  181.  
  182.           [c:\] activate "Take Command" max "Take Command is Great!"
  183.  
  184.  You can use wildcards, including extended wildcards, in the window parameter. 
  185.  This is useful when you only know part of the current window title.  For 
  186.  example, if you are using the OS/2 EPM editor to edit the file TCMD.DOC, the 
  187.  session might have a title like "EPM - TCMD.DOC".  To activate this window 
  188.  without knowing the full title, use a command like this: 
  189.  
  190.           [c:\] activate "EPM*"
  191.  
  192.  When this command is executed, ACTIVATE will select the first window whose 
  193.  name begins with "EPM", regardless of the rest of the title. 
  194.  
  195.  
  196. ΓòÉΓòÉΓòÉ 3.3. ALIAS - Create or display aliases ΓòÉΓòÉΓòÉ
  197.  
  198.  Purpose:    Create new command names that execute one or more commands or 
  199.              redefine default options for existing commands; assign commands to 
  200.              keystrokes; load or display the list of defined alias names. 
  201.  
  202.  Format:     ALIAS [/P /R file...] [name [=][value ]] 
  203.  
  204.              file :  One or more files to read for alias definitions. 
  205.              name :  Name for an alias, or for the key to execute the alias. 
  206.              value :  Text to be substituted for the alias name. 
  207.  
  208.              /P(ause)                 /R(ead alias file) 
  209.  
  210.  See also:  UNALIAS. 
  211.  
  212.  Usage: 
  213.  
  214.  The ALIAS command lets you create new command names or redefine internal 
  215.  commands.  It also lets you assign one or more commands to a single keystroke. 
  216.  An alias is often used to execute a complex series of commands with a few 
  217.  keystrokes or to create "in memory batch files" that run much faster than 
  218.  disk-based batch files. 
  219.  
  220.  For example, if you would rather type D instead of DIR /W, you would use the 
  221.  command: 
  222.  
  223.           [c:\] alias d = dir /w
  224.  
  225.  Now when you type a single d as a command, it will be translated into a DIR /W 
  226.  command. 
  227.  
  228.  If you define aliases for commonly used application programs, you can often 
  229.  remove the directories they're stored in from the PATH. For example, if you 
  230.  use Quattro Pro and had the C:\QPRO directory in your path, you could define 
  231.  the following alias: 
  232.  
  233.           [c:\] alias qpro = c:\qpro\q.exe
  234.  
  235.  With this alias defined, you can probably remove C:\QPRO from your path. 
  236.  Quattro Pro will now load much faster than it would if Take Command had to 
  237.  search the PATH for it.  In addition, the PATH can be shorter, which will 
  238.  speed up searches for other programs. 
  239.  
  240.  If you apply this technique for each application program, you can often reduce 
  241.  your PATH to just two or three directories containing utility programs, and 
  242.  significantly reduce the time it takes to load most software on your system. 
  243.  Before removing a directory from the PATH, you will need to define aliases for 
  244.  all the executable programs you commonly use which are stored in that 
  245.  directory. 
  246.  
  247.  Aliases are stored in memory, and are not saved automatically when you turn 
  248.  off your computer or end your current session.  See below for information on 
  249.  saving and reloading your aliases. 
  250.  
  251.  Multiple Commands and Special Characters in Aliases 
  252.  
  253.  An alias can represent more than one command.  For example: 
  254.  
  255.           [c:\] alias letters = `cd \letters & text`
  256.  
  257.  creates a new command called LETTERS.  The command first uses CD to change to 
  258.  a subdirectory called \LETTERS and then runs a program called TEXT.  The 
  259.  ampersand [&] is the command separator and indicates that the two commands are 
  260.  distinct and should be executed sequentially. 
  261.  
  262.  Aliases make extensive use of the command separator, and the parameter 
  263.  character, and may also use the escape character.  These characters differ 
  264.  between 4OS2 and Take Command.  In the text and examples below, we use the 
  265.  Take Command characters.  If you want to use the same aliases under different 
  266.  command processors, see 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility. 
  267.  
  268.  When you type alias commands at the command line or in a batch file, you must 
  269.  use back quotes [`] around the definition if it contains multiple commands, 
  270.  parameters (discussed below), environment variables, redirection, or piping. 
  271.  The back quotes prevent premature expansion of these arguments.  You may use 
  272.  back quotes around other definitions, but they are not required. (You do not 
  273.  need back quotes when your aliases are loaded from an ALIAS /R file; see below 
  274.  for details.) The examples above and below include back quotes only when they 
  275.  are required. 
  276.  
  277.  Nested Aliases 
  278.  
  279.  Aliases may invoke internal commands, external commands, or other aliases. 
  280.  (However, an alias may not invoke itself, except in special cases where an IF 
  281.  or IFF command is used to prevent an infinite loop.) The two aliases below 
  282.  demonstrate alias nesting (one alias invoking another).  The first line 
  283.  defines an alias which runs a program called WP.EXE that is in the E:\WP60\ 
  284.  subdirectory.  The second alias changes directories with the PUSHD command, 
  285.  runs the WP alias, and then returns to the original directory with the POPD 
  286.  command: 
  287.  
  288.           [c:\] alias wp = e:\wp60\wp.exe
  289.           [c:\] alias w = `pushd c:\wp & wp & popd`
  290.  
  291.  The second alias above could have included the full path and name of the 
  292.  WP.EXE program instead of calling the WP alias. However, writing two aliases 
  293.  makes the second one easier to read and understand, and makes the first alias 
  294.  available for independent use.  If you rename the WP.EXE program or move it to 
  295.  a new directory, only the first alias needs to be changed. 
  296.  
  297.  Temporarily Disabling Aliases 
  298.  
  299.  If you put an asterisk [*] immediately before a command in the value of an 
  300.  alias definition (the part after the equal sign), it tells Take Command not to 
  301.  attempt to interpret that command as another (nested) alias.  An asterisk used 
  302.  this way must be preceded by a space or the command separator and followed 
  303.  immediately by an internal or external command name. 
  304.  
  305.  By using an asterisk, you can redefine the default options for any internal 
  306.  command.  For example, suppose that you always want to use the DIR command 
  307.  with the /2 (two column) and /P (pause at the end of each page) options: 
  308.  
  309.           [c:\] alias dir = *dir /2/p
  310.  
  311.  If you didn't include the asterisk, the second DIR on the line would be the 
  312.  name of the alias itself, and Take Command would repeatedly re- invoke the DIR 
  313.  alias, rather than running the DIR command.  This would cause an "Alias loop" 
  314.  or "Command line too long" error. 
  315.  
  316.  An asterisk also helps you keep the names of internal commands from 
  317.  conflicting with the names of external programs.  For example, suppose you 
  318.  have a program called LIST.COM.  Normally, the internal LIST command will run 
  319.  anytime you type LIST.  But two simple aliases will give you access to both 
  320.  the LIST.COM program and the LIST command: 
  321.  
  322.           [c:\] alias list = c:\util\list.com
  323.           [c:\] alias display = *list
  324.  
  325.  The first line above defines LIST as an alias for the LIST.COM program.  If 
  326.  you stopped there, the external program would run every time you typed LIST 
  327.  and you would not have easy access to the internal LIST command.  The second 
  328.  line renames the internal LIST command as DISPLAY.  The asterisk is needed in 
  329.  the second command to indicate that the following word means the internal 
  330.  command LIST, not the LIST alias which runs your external program. 
  331.  
  332.  You can also use an asterisk before a command that you enter at the command 
  333.  line or in a batch file.  If you do, that command won't be interpreted as an 
  334.  alias.  This can be useful when you want to be sure you are running the true, 
  335.  original command and not an alias with the same name, or temporarily defeat 
  336.  the purpose of an alias which changes the meaning or behavior of a command. 
  337.  
  338.  Partial Alias Names 
  339.  
  340.  You can also use an asterisk in the name of an alias.  When you do, the 
  341.  characters following the asterisk are optional when you invoke the alias 
  342.  command.  (Use of an asterisk in the alias name is unrelated to the use of an 
  343.  asterisk in the alias value discussed above.)  For example, with this alias: 
  344.  
  345.           [c:\] alias wher*eis = dir /sp
  346.  
  347.  the new command, WHEREIS, can be invoked as WHER, WHERE, WHEREI, or WHEREIS. 
  348.  Now if you type: 
  349.  
  350.           [c:\] where myfile.txt
  351.  
  352.  The WHEREIS alias will be expanded to the command: 
  353.  
  354.           dir /sp myfile.txt
  355.  
  356.  Keystroke Aliases 
  357.  
  358.  If you want to assign an alias to a keystroke, use the key name on the left 
  359.  side of the equal sign, preceded by an at sign [@]. For example, to assign the 
  360.  command DIR /W to the F4 key, type 
  361.  
  362.           [c:\] alias @F4 = dir /w
  363.  
  364.  See Keys and Key Names for a complete listing of key names and a description 
  365.  of the key name format. You can not use Alt key names (e.g. Alt-D) for 
  366.  keystroke aliases because these names are used by OS/2 for "accelerator" 
  367.  (shortcut) keys for menu items. 
  368.  
  369.  When you define keystroke aliases, the assignments will only be in effect at 
  370.  the command line, not inside application programs.  Be careful not to assign 
  371.  aliases to keys that are already used at the command line (like F1 for Help). 
  372.  The command-line meanings take precedence and the keystroke alias will never 
  373.  be invoked.  If you want to use one of the command-line keys for an alias 
  374.  instead of its normal meaning, you must first disable its regular use with the 
  375.  NormalKey or NormalEditKey directive in your .INI file. 
  376.  
  377.  If you define a keystroke alias with a single at sign as shown above, then, 
  378.  when you press the F4 key, the value of the alias (DIR /W above) will be 
  379.  placed on the command line for you.  You can type additional parameters if you 
  380.  wish and then press Enter to execute the command.  With this particular alias, 
  381.  you can define the files that you want to display after pressing F4 and before 
  382.  pressing Enter to execute the command. 
  383.  
  384.  If you want the keystroke alias to take action automatically without waiting 
  385.  for you to edit the command line or press Enter, you can begin the definition 
  386.  with two at signs [@@]. Take Command will execute the alias "silently," 
  387.  without displaying its text on the command line. For example, this command 
  388.  will assign an alias to the F6 key that uses the CDD command to take you back 
  389.  to the previous default directory: 
  390.  
  391.           [c:\] alias @@f6 = cdd -
  392.  
  393.  You can also define a keystroke alias by using "@" or "@@" plus a scan code 
  394.  for one of the permissible keys (see the Key Code Tables for a list of scan 
  395.  codes).  In most cases it will be easier to use key names.  Scan codes should 
  396.  only be used with unusual keyboards where a key name is not available for the 
  397.  key you are using. 
  398.  
  399.  Displaying Aliases 
  400.  
  401.  If you want to see a list of all current ALIAS commands, type: 
  402.  
  403.           [c:\] alias
  404.  
  405.  You can also view the definition of a single alias.  If you want to see the 
  406.  definition of the alias LIST, you can type: 
  407.  
  408.           [c:\] alias list
  409.  
  410.  Saving and Reloading Your Aliases 
  411.  
  412.  You can save your aliases to a file called ALIAS.LST this way: 
  413.  
  414.           [c:\] alias > alias.lst
  415.  
  416.  You can then reload all the alias definitions in the file the next time you 
  417.  boot up with the command: 
  418.  
  419.           [c:\] alias /r alias.lst
  420.  
  421.  This is much faster than defining each alias individually in a batch file.  If 
  422.  you keep your alias definitions in a separate file which you load when your 
  423.  system starts, you can edit them with a text editor, reload the edited file 
  424.  with ALIAS /R, and know that the same alias list will be loaded the next time 
  425.  you boot your computer. 
  426.  
  427.  When you define aliases in a file that will be read with the ALIAS /R command, 
  428.  you do not need back quotes around the value, even if back quotes would 
  429.  normally be required when defining the same alias at the command line or in a 
  430.  batch file. 
  431.  
  432.  To remove an alias, use the UNALIAS command. 
  433.  
  434.  Alias Parameters 
  435.  
  436.  Aliases can use command-line arguments or parameters like those in batch 
  437.  files.  The command-line arguments are numbered from %0 to %127.  %0 contains 
  438.  the alias name.  It is up to the alias to determine the meaning of the other 
  439.  parameters. You can use quotation marks to pass spaces, tabs, commas, and 
  440.  other special characters in an alias parameter; see Argument Quoting for 
  441.  details. 
  442.  
  443.  Parameters that are referred to in an alias, but which are missing on the 
  444.  command line, appear as empty strings inside the alias.  For example, if you 
  445.  put two parameters on the command line, any reference in the alias to %3 or 
  446.  any higher-numbered parameter will be interpreted as an empty string. 
  447.  
  448.  The parameter %n$ has a special meaning.  Take Command interprets it to mean 
  449.  "the entire command line, from argument n to the end."  If n is not specified, 
  450.  it has a default value of 1, so %$means "the entire command line after the 
  451.  alias name."  The special parameter %# contains the number of command-line 
  452.  arguments. 
  453.  
  454.  For example, the following alias will change directories, perform a command, 
  455.  and return to the original directory: 
  456.  
  457.           [c:\] alias in = `pushd %1 & %2$ & popd`
  458.  
  459.  When this alias is invoked as: 
  460.  
  461.           [c:\] in c:\comm mycomm /xmodem /2400
  462.  
  463.  the first parameter, %1, has the value c:\comm.  %2 is mycomm,  3 is /xmodem, 
  464.  and %4 is /2400. The command line expands into these three separate commands: 
  465.  
  466.           pushd c:\comm
  467.           mycomm /xmodem /2400
  468.           popd
  469.  
  470.  This next example uses the IFF command to redefine the defaults for SET.  It 
  471.  should be entered on one line: 
  472.  
  473.           [c:\] alias set = `iff %# == 0 then & *set /p & else & *set %$ &
  474.   endiff`
  475.  
  476.  This modifies the SET command so that if SET is entered with no arguments, it 
  477.  is replaced by SET /P (pause after displaying each page), but if SET is 
  478.  followed by an argument, it behaves normally. Note the use of asterisks (*set) 
  479.  to prevent alias loops. 
  480.  
  481.  If an alias uses parameters, command-line arguments will be deleted up to and 
  482.  including the highest referenced argument.  For example, if an alias refers 
  483.  only to %1 and %4, then the first and fourth arguments will be used, the 
  484.  second and third arguments will be discarded, and any additional arguments 
  485.  beyond the fourth will be appended to the expanded command (after the value 
  486.  portion of the alias).  If an alias uses no parameters, all of the command- 
  487.  line arguments will be appended to the expanded command. 
  488.  
  489.  Aliases also have full access to all variables in the environment, internal 
  490.  variables, and variable functions.  For example, you can create a simple 
  491.  command-line calculator this way (enter this on one line): 
  492.  
  493.           [c:\] alias calc = `echo The answer is: %@eval[%$]`
  494.  
  495.  Now, if you enter: 
  496.  
  497.           [c:\] calc 5 * 6
  498.  
  499.  the alias will display: 
  500.  
  501.           The answer is: 30
  502.  
  503.  Local and Global Aliases 
  504.  
  505.  The aliases can be stored in either a "local" or "global" list. 
  506.  
  507.  With a local alias list, any changes made to the aliases will only affect the 
  508.  current copy of Take Command.  They will not be visible in other shells or 
  509.  other sessions. 
  510.  
  511.  With a global alias list, all copies of Take Command will share the same alias 
  512.  list, and any changes made to the aliases in one copy will affect all other 
  513.  copies.  This is the default. 
  514.  
  515.  You can control the type of alias list with the LocalAliases directive in the 
  516.  .INI file, and with the /L and /LA options of the START command. 
  517.  
  518.  Whenever you start a secondary shell which uses a local alias list, it 
  519.  inherits a copy of the aliases from the previous shell. However, any changes 
  520.  to the alias made in the secondary shell will affect only that shell.  If you 
  521.  want changes made in a secondary shell to affect the previous shell, use a 
  522.  global alias list in both shells. 
  523.  
  524.  Retaining Global Aliases with SHRALIAS 
  525.  
  526.  If you select a global alias list you can share the aliases among all copies 
  527.  of Take Command running in any session.  When you close all Take Command 
  528.  sessions, the memory for the global alias list is released, and a new, empty 
  529.  alias list is created the next time you start Take Command. 
  530.  
  531.  If you want the aliases to be retained in memory even when no Take Command 
  532.  session is running, see the SHRALIAS command, which retains the global alias, 
  533.  command history, and directory history lists. 
  534.  
  535.  SHRALIAS retains the alias list in memory, but cannot preserve it when OS/2 
  536.  itself is shut down.  To save your aliases when restarting OS/2, you must 
  537.  store them in a file and reload them after the system restarts.  For details 
  538.  on how to do so, see Saving and Reloading Your Aliases (above). 
  539.  
  540.  The UNKNOWN_CMD Alias 
  541.  
  542.  If you create an alias with the name UNKNOWN_CMD, it will be executed any time 
  543.  Take Command would normally issue an "Unknown command" error message.  This 
  544.  allows you to define your own handler for unknown commands.  When the 
  545.  UNKNOWN_CMD alias is executed, the command line which generated the error is 
  546.  passed to the alias for possible processing. 
  547.  
  548.  Use caution when you create the UNKNOWN_CMD alias.  If the alias contains an 
  549.  unknown command, it will be called repeatedly and Take Command will lock up in 
  550.  an infinite loop. 
  551.  
  552.  Options: 
  553.  
  554.     /P      (Pause) This option is only effective when ALIAS is used to display 
  555.             existing definitions.  It pauses the display after each page and 
  556.             waits for a keystroke before continuing (see Page and File 
  557.             Prompts). 
  558.  
  559.     /R      (Read file) This option loads an alias list from a file. The format 
  560.             of the file is the same as that of the ALIAS display: 
  561.  
  562.                                 name=value
  563.  
  564.             where name is the name of the alias and value is its value.  You 
  565.             can use an equal sign [=] or space to separate the name and value. 
  566.             Back quotes are not required around the value.  You can add 
  567.             comments to the file by starting each comment line with a colon 
  568.             [:].  You can load multiple files with one ALIAS /R command by 
  569.             placing the names on the command line, separated by spaces: 
  570.  
  571.                                 [c:\] alias /r alias1.lst alias2.lst
  572.  
  573.             Each definition in an ALIAS /R file can be up to 2047 characters 
  574.             long. The definitions can span multiple lines in the file if each 
  575.             line, except the last, is terminated with an escape character. 
  576.  
  577.  
  578. ΓòÉΓòÉΓòÉ 3.4. ATTRIB - Change file attributes ΓòÉΓòÉΓòÉ
  579.  
  580.  Purpose:    Change or view file and subdirectory attributes. 
  581.  
  582.  Format:     ATTRIB [/A:[[-]rhsda] /D /P /Q /S] [+|-[AHRS]] files ... 
  583.  
  584.              files :  A file, directory, or list of files or directories on 
  585.              which to operate. 
  586.  
  587.              /A(ttribute select)         /Q(uiet) 
  588.              /D(irectories)              /S(ubdirectories) 
  589.              /P(ause) 
  590.  
  591.              Attribute flags: 
  592.  
  593.               +A     Set the archive attribute 
  594.               -A     Clear the archive attribute 
  595.               +H     Set the hidden attribute 
  596.               -H     Clear the hidden attribute 
  597.               +R     Set the read-only attribute 
  598.               -R     Clear the read-only attribute 
  599.               +S     Set the system attribute 
  600.               -S     Clear the system attribute 
  601.  
  602.  File Selection: 
  603.  
  604.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  605.  
  606.  Usage: 
  607.  
  608.  Every file and subdirectory has 4 attributes that can be turned on (set) or 
  609.  turned off (cleared):  Archive, Hidden, Read-only, and System. 
  610.  
  611.  The ATTRIB command lets you set or clear attributes for any file, group of 
  612.  files, or subdirectory.  You can view file attributes by entering ATTRIB 
  613.  without specifying new attributes (i.e., without the [+|-[AHRS]] part of the 
  614.  format), or with the DIR /T command. 
  615.  
  616.  For example, you can set the read-only and hidden attributes for the file 
  617.  MEMO: 
  618.  
  619.           [c:\] attrib +rh memo
  620.  
  621.  Attribute options apply to the file(s) that follow the options on the ATTRIB 
  622.  command line.  The example below shows how to set different attributes on 
  623.  different files with a single command.  It sets the archive attribute for all 
  624.  .TXT files, then sets the system attribute and clears the archive attribute 
  625.  for TEST.COM: 
  626.  
  627.           [c:\] attrib +a *.txt +s -a test.com
  628.  
  629.  Your operating system also supports "D" (subdirectory) and "V" (volume label) 
  630.  attributes.  These attributes cannot be altered with ATTRIB; they are designed 
  631.  to be controlled only by the operating system itself. 
  632.  
  633.  Options: 
  634.  
  635.     /A      (Attribute select):  Select only those files that have the 
  636.             specified attribute(s) set.  Preceding the attribute character with 
  637.             a hyphen [-] will select files that do not have that attribute set. 
  638.             The colon [:] after /A is required.  The attributes are: 
  639.  
  640.                          R  Read-only 
  641.                          H  Hidden 
  642.                          S  System 
  643.                          D  Subdirectory 
  644.                          A  Archive 
  645.  
  646.             If no attributes are listed at all (e.g., /A), ATTRIB will select 
  647.             all files and subdirectories including hidden and system files.  If 
  648.             attributes are combined, all the specified attributes must match 
  649.             for a file to be selected.  For example, /A:RHS will select only 
  650.             those files with all three attributes set. 
  651.  
  652.     /D      (Directories) If you use the /D option, ATTRIB will modify the 
  653.             attributes of subdirectories in addition to files (yes, you can 
  654.             have a hidden subdirectory): 
  655.  
  656.                                 [c:\] attrib /d +h c:\mydir
  657.  
  658.             In addition, the /D option will keep ATTRIB from appending "\*.*" 
  659.             to the end of a directory name and modifying the attributes of all 
  660.             the files in the subdirectory. 
  661.  
  662.             If you use a directory name instead of a file name, and omit /D, 
  663.             ATTRIB will append "\*.*" to the end of the name and act on all 
  664.             files in that directory, rather than acting on the directory 
  665.             itself. 
  666.  
  667.     /P      (Pause) Wait for a key to be pressed after each screen page before 
  668.             continuing the display.  Your options at the prompt are explained 
  669.             in detail under Page and File Prompts. 
  670.  
  671.     /Q      (Quiet) This option turns off ATTRIB's normal screen output. It is 
  672.             most useful in batch files. 
  673.  
  674.     /S      (Subdirectories) If you use the /S option, the ATTRIB command will 
  675.             be applied to all matching files in the current or named directory 
  676.             and all of its subdirectories. 
  677.  
  678.  
  679. ΓòÉΓòÉΓòÉ 3.5. BEEP - Beep the speaker ΓòÉΓòÉΓòÉ
  680.  
  681.  Purpose:    Beep the speaker or play simple music. 
  682.  
  683.  Format:     BEEP [frequency duration ...] 
  684.  
  685.              frequency :  The beep frequency in Hertz (cycles per second). 
  686.              duration :  The beep length in 1/18th second intervals. 
  687.  
  688.  Usage: 
  689.  
  690.  BEEP generates a sound through your computer's speaker.  It is normally used 
  691.  in batch files to signal that an operation has been completed, or that the 
  692.  computer needs attention. 
  693.  
  694.  Because BEEP allows you to specify the frequency and duration of the sound, 
  695.  you can also use it to play simple music or to create different kinds of 
  696.  signals for the user. 
  697.  
  698.  You can include as many frequency and duration pairs as you wish. No sound 
  699.  will be generated for frequencies less than 20 Hz, allowing you to insert 
  700.  short delays.  The default value for frequency is 440 Hz; the default value 
  701.  for duration is 2. 
  702.  
  703.  This batch file fragment runs a program called DEMO, then plays a few notes 
  704.  and waits for you to press a key: 
  705.  
  706.           demo
  707.           beep 440 4  600 2  1040 6
  708.           pause Finished with the demo - hit a key
  709.  
  710.   The following table gives the frequency values for a five octave range 
  711.  (middle C is 262 Hz): 
  712.  
  713.           ΓòöΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòñΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòù
  714.           Γòæ C      Γöé  131  Γöé  262  Γöé  523  Γöé  1046  Γöé  2093 Γòæ
  715.           Γòæ C#/Db  Γöé  139  Γöé  277  Γöé  554  Γöé  1108  Γöé  2217 Γòæ
  716.           Γòæ D      Γöé  147  Γöé  294  Γöé  587  Γöé  1175  Γöé  2349 Γòæ
  717.           Γòæ D#/Eb  Γöé  156  Γöé  311  Γöé  622  Γöé  1244  Γöé  2489 Γòæ
  718.           Γòæ E      Γöé  165  Γöé  330  Γöé  659  Γöé  1318  Γöé  2637 Γòæ
  719.           Γòæ F      Γöé  175  Γöé  349  Γöé  698  Γöé  1397  Γöé  2794 Γòæ
  720.           Γòæ F#/Gb  Γöé  185  Γöé  370  Γöé  740  Γöé  1480  Γöé  2960 Γòæ
  721.           Γòæ G      Γöé  196  Γöé  392  Γöé  784  Γöé  1568  Γöé  3136 Γòæ
  722.           Γòæ G#/Ab  Γöé  208  Γöé  415  Γöé  831  Γöé  1662  Γöé  3322 Γòæ
  723.           Γòæ A      Γöé  220  Γöé  440  Γöé  880  Γöé  1760  Γöé  3520 Γòæ
  724.           Γòæ A#/Bb  Γöé  233  Γöé  466  Γöé  932  Γöé  1866  Γöé  3729 Γòæ
  725.           Γòæ B      Γöé  248  Γöé  494  Γöé  988  Γöé  1973  Γöé  3951 Γòæ
  726.           ΓòÜΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòºΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓòÉΓò¥
  727.  
  728.  
  729. ΓòÉΓòÉΓòÉ 3.6. CALL - Execute one batch file from another ΓòÉΓòÉΓòÉ
  730.  
  731.  Purpose:    Execute one batch file from within another. 
  732.  
  733.  Format:     CALL file 
  734.  
  735.              file :  The batch file to execute. 
  736.  
  737.  See also:  CANCEL and QUIT. 
  738.  
  739.  Usage: 
  740.  
  741.  CALL allows batch files to call other batch files (batch file nesting).  The 
  742.  calling batch file is suspended while the called (second) batch file runs. 
  743.  When the second batch file finishes, the original batch file resumes execution 
  744.  at the next command.  If you execute a batch file from inside another batch 
  745.  file without using CALL, the first batch file is terminated before the second 
  746.  one starts. 
  747.  
  748.  Take Command supports batch file nesting up to ten levels deep. 
  749.  
  750.  The current ECHO state is inherited by a called batch file. 
  751.  
  752.  A called batch file will return to the calling file after processing the last 
  753.  line in the called file, or when a QUIT command is executed.  A called batch 
  754.  file should always return in this way, or terminate all batch files with 
  755.  CANCEL.  Restarting (or CALLing) the original batch file from within a called 
  756.  file will prevent Take Command from detecting that you've left the second 
  757.  file, and it may cause an infinite loop or a stack overflow. 
  758.  
  759.  CALL returns an exit code which matches the batch file return code. You can 
  760.  test this exit code with the %_? or %? environment variable, and use it with 
  761.  conditional commands (&& and ||). 
  762.  
  763.  
  764. ΓòÉΓòÉΓòÉ 3.7. CANCEL - End all batch files ΓòÉΓòÉΓòÉ
  765.  
  766.  Purpose:    Terminate batch file processing. 
  767.  
  768.  Format:     CANCEL [value ] 
  769.  
  770.              value :  The exit code from 0 to 255 to return to Take Command. 
  771.  
  772.  See also:  CALL and QUIT. 
  773.  
  774.  Usage: 
  775.  
  776.  The CANCEL command ends all batch file processing, regardless of the batch 
  777.  file nesting level.  Use QUIT to end a nested batch file and return to the 
  778.  previous batch file. 
  779.  
  780.  You can CANCEL at any point in a batch file.  If CANCEL is used from within an 
  781.  alias it will end execution of both the alias and any batch file(s) which are 
  782.  running at the time. 
  783.  
  784.  The following batch file fragment compares an input line to "end" and 
  785.  terminates all batch file processing if it matches: 
  786.  
  787.           input Enter your choice:  %%option
  788.           if "%option" == "end" cancel
  789.  
  790.  If you specify a value, CANCEL will set the ERRORLEVEL or exit code to that 
  791.  value (see the IF command, and the %? variable). 
  792.  
  793.  
  794. ΓòÉΓòÉΓòÉ 3.8. CD - Change directory ΓòÉΓòÉΓòÉ
  795.  
  796.  Purpose:    Display or change the current directory. 
  797.  
  798.  Format:     CD [ path | - ] 
  799.                 or 
  800.              CHDIR [ path | - ] 
  801.  
  802.              path :  The directory to change to, including an optional drive 
  803.              name. 
  804.  
  805.  See also:  CDD, MD, PUSHD, RD, and CDPATH. 
  806.  
  807.  Usage: 
  808.  
  809.  CD and CHDIR are synonyms.  You can use either one. 
  810.  
  811.  CD lets you navigate through the disk subdirectory structure by changing the 
  812.  current working directory.  If you enter CD and a directory name, the named 
  813.  directory becomes the new current directory.  For example, to change to the 
  814.  subdirectory C:\FINANCE\MYFILES: 
  815.  
  816.           [c:\] cd \finance\myfiles
  817.           [c:\finance\myfiles]
  818.  
  819.  Every disk drive on the system has its own current directory. Specifying both 
  820.  a drive and a directory in the CD command will change the current directory on 
  821.  the specified drive, but will not change the default drive.  For example, to 
  822.  change the default directory on drive A: 
  823.  
  824.           [c:\] cd a:\utility
  825.           [c:\]
  826.  
  827.  Notice that this command does not change to drive A:.  Use the CDD command to 
  828.  change the current drive and directory at the same time. 
  829.  
  830.  You can change to the parent directory with CD ..; you can also go up one 
  831.  additional directory level with each additional [.]. For example, CD .... will 
  832.  go up three levels in the directory tree (see Extended Parent Directory 
  833.  Names).  You can move to a sibling directory -- one that branches from the 
  834.  same parent directory as the current subdirectory -- with a command like CD 
  835.  ..\newdir. 
  836.  
  837.  If you enter CD with no argument or with only a disk drive name, it will 
  838.  display the current directory on the default or named drive. 
  839.  
  840.  CD saves the current directory before changing to a new directory. You can 
  841.  switch back to the previous directory by entering CD -. (There must be a space 
  842.  between the CD command and the hyphen.)  You can switch back and forth between 
  843.  two directories by repeatedly entering CD -.  The saved directory is the same 
  844.  for both the CD and CDD commands.  Drive changes and automatic directory 
  845.  changes also modify the saved directory, so you can use CD - to return to a 
  846.  directory that you exited with an automatic directory change. 
  847.  
  848.  Directory changes made with CD are recorded for display in the directory 
  849.  history window. 
  850.  
  851.  CD never changes the default drive.  If you change directories on one drive, 
  852.  switch to another drive, and then enter CD -, the directory will be restored 
  853.  on the first drive but the current drive will not be changed. 
  854.  
  855.  If CD can't change directly to the specified directory, it will look for the 
  856.  CDPATH variable; see CDPATH for details. 
  857.  
  858.  
  859. ΓòÉΓòÉΓòÉ 3.9. CDD - Change drive and directory ΓòÉΓòÉΓòÉ
  860.  
  861.  Purpose:    Change the current disk drive and directory. 
  862.  
  863.  Format:     CDD [ path | - ] 
  864.  
  865.              path :  The name of the directory (or drive and directory) to 
  866.              change to. 
  867.  
  868.  See also:  CD, MD, PUSHD, RD, and CDPATH. 
  869.  
  870.  Usage: 
  871.  
  872.  CDD is similar to the CD command, except that it also changes the default disk 
  873.  drive if one is specified.  CDD will change to the directory and drive you 
  874.  name.  To change from the root directory on drive A to the subdirectory C:\WP: 
  875.  
  876.           [a:\] cdd c:\wp
  877.           [c:\wp]
  878.  
  879.  You can change to the parent directory with CDD ..; you can also go up one 
  880.  additional directory level with each additional [.]. For example, CDD .... 
  881.  will go up three levels in the directory tree. 
  882.  
  883.  CDD saves the current drive and directory before changing to a new directory. 
  884.  You can switch back to the previous drive and directory by entering CDD -. 
  885.  (There must be a space between the CDD command and the hyphen.)  You can 
  886.  switch back and forth between two drives and directories by repeatedly 
  887.  entering CDD -.  The saved directory is the same for both the CD and CDD 
  888.  commands.  Drive changes and automatic directory changes also modify the saved 
  889.  directory, so you can use CDD - to return to a directory that you exited with 
  890.  a drive change or an automatic directory change. 
  891.  
  892.  Directory changes made with CDD are recorded for display in the directory 
  893.  history window. 
  894.  
  895.  If CDD can't change directly to the specified directory, it will look for the 
  896.  CDPATH variable; see CDPATH for details. 
  897.  
  898.  
  899. ΓòÉΓòÉΓòÉ 3.10. CHCP - Change the current code page ΓòÉΓòÉΓòÉ
  900.  
  901.  Purpose:    Display or change the current system code page. 
  902.  
  903.  Format:     CHCP [n ] 
  904.  
  905.              n :  A system code page number. 
  906.  
  907.  Usage: 
  908.  
  909.  Code page switching allows you to select different character sets for language 
  910.  support. 
  911.  
  912.  If you enter CHCP without a number, the current active code page is displayed, 
  913.  along with a list of all active code pages : 
  914.  
  915.           [c:\] chcp
  916.           Active code page: 437
  917.           Prepared code pages:  273 274 277 278 280 282 284 285 297 437 500
  918.           850 860 863 865 932 942 852 857 861 870 871 1026 1004
  919.  
  920.  If you enter CHCP plus a code page number, the system code page is changed. 
  921.  For example, to set the code page to multilingual: 
  922.  
  923.           [c:\] chcp 850
  924.  
  925.  CHCP accepts one of the prepared system code pages.  An error message is 
  926.  displayed if a code page is selected that has not been prepared for the 
  927.  system. 
  928.  
  929.  See your OS/2 documentation for more information on CHCP. 
  930.  
  931.  
  932. ΓòÉΓòÉΓòÉ 3.11. CLS - Clear the screen ΓòÉΓòÉΓòÉ
  933.  
  934.  Purpose:    Clear the video display and move the cursor to the upper left 
  935.              corner; optionally change the default display colors. 
  936.  
  937.  Format:     CLS [/C] [[BRIght] fg ON [BRIght] bg ] 
  938.  
  939.              fg :  The new foreground color 
  940.              bg :  The new background color 
  941.  
  942.              /C  Clear scrollback buffer 
  943.  
  944.  Usage: 
  945.  
  946.  CLS can be used to clear the screen without changing colors, or to clear the 
  947.  screen and change the screen colors simultaneously. These two examples show 
  948.  how to clear the screen to the default colors, and to bright white letters on 
  949.  a blue background: 
  950.  
  951.           [c:\] cls
  952.           [c:\] cls bright white on blue
  953.  
  954.  CLS is often used in batch files to clear the screen before displaying text. 
  955.  
  956.  See Colors and Color Names for details about colors. 
  957.  
  958.  Option: 
  959.  
  960.     /C      (Clear buffer)  Clears the entire SCROLLBACK, not just the visible 
  961.             portion of the Take Command screen. 
  962.  
  963.  
  964. ΓòÉΓòÉΓòÉ 3.12. COLOR - Change display colors ΓòÉΓòÉΓòÉ
  965.  
  966.  Purpose:    Change the default display colors. 
  967.  
  968.  Format:     COLOR [BRIght] fg ON [ BRIght] bg 
  969.  
  970.              fg :  The new foreground color 
  971.              bg :  The new background color 
  972.  
  973.  See also:  CLS, and Colors and Color Names for details about using colors. 
  974.  
  975.  Usage: 
  976.  
  977.  COLOR is normally used in batch files before displaying text. For example, to 
  978.  set screen colors to bright white on blue, you can use this command: 
  979.  
  980.           [c:\] color bright white on blue
  981.  
  982.  
  983. ΓòÉΓòÉΓòÉ 3.13. COPY - Copy files ΓòÉΓòÉΓòÉ
  984.  
  985.  Purpose:    Copy data between disks, directories, files, or physical hardware 
  986.              devices (such as your printer or serial port). 
  987.  
  988.  Format:     COPY [/A:[[-]rhsda] /C /H /M /N /P /Q /R /S /T /U /V] source [+] 
  989.              ... [/A /B] destination [/A /B] 
  990.  
  991.              source :  A file or list of files or a device to copy from. 
  992.              destination :  A file, directory, or device to copy to. 
  993.  
  994.              /A(SCII)                    /P(rompt) 
  995.              /A:(ttribute select)        /Q(uiet) 
  996.              /B(inary)                   /R(eplace) 
  997.              /C(hanged)                  /S(ubdirectories) 
  998.              /H(idden)                   /T(otals) 
  999.              /M(odified)                 /U(pdate) 
  1000.              /N(othing)                  /V(erify) 
  1001.  
  1002.  See also:  ATTRIB, MOVE, and REN. 
  1003.  
  1004.  File Selection: 
  1005.  
  1006.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  1007.  Date, time, or size ranges anywhere on the line apply to all source files. 
  1008.  
  1009.  Usage: 
  1010.  
  1011.  The COPY command accepts all traditional syntax and options and adds several 
  1012.  new features. 
  1013.  
  1014.  The simplest use of COPY is to make a copy of a file, like this example which 
  1015.  makes a copy of a file called FILE1.ABC: 
  1016.  
  1017.           [c:\] copy file1.abc file2.def
  1018.  
  1019.  You can also copy a file to another drive and/or directory.  The following 
  1020.  command copies FILE1 to the \MYDIR directory on drive E: 
  1021.  
  1022.           [c:\] copy file1 e:\mydir
  1023.  
  1024.  You can copy several files at once by using wildcards: 
  1025.  
  1026.           [c:\] copy *.txt e:\mydir
  1027.  
  1028.  You can also list several source files in one command.  The following command 
  1029.  copies 3 files from the current directory to the \MYDIR directory on drive E: 
  1030.  
  1031.           [c:\] copy file1 file2 file3 e:\mydir
  1032.  
  1033.  The way COPY interprets your command line depends on how many arguments (file, 
  1034.  directory, or device names) are on the line, and whether the arguments are 
  1035.  separated with [+] signs or spaces. 
  1036.  
  1037.  If there is only one argument on the line, COPY assumes it is the source, and 
  1038.  uses the current drive and directory as the destination.  For example, the 
  1039.  following command copies all the .DAT files on drive A to the current 
  1040.  directory on drive C: 
  1041.  
  1042.           [c:\] copy a:*.dat
  1043.  
  1044.  If there are two or more arguments on the line and [+] signs are not used, 
  1045.  then COPY assumes that the last argument is the destination and copies all 
  1046.  source files to this new location.  If the destinationis a drive, directory, 
  1047.  or device name then the source files are copied individually to the new 
  1048.  location.  If the destination is a file name, the first source file is copied 
  1049.  to the destination, and any additional source files are then appended to the 
  1050.  new destination file. 
  1051.  
  1052.  For example, the first of these commands copies the .DAT files from the 
  1053.  current directory on drive A individually to C:\MYDIR (which must already 
  1054.  exist as a directory); the second appends all the .DAT files together into one 
  1055.  large file called C:\DATA (assuming C:\DATA is not a directory): 
  1056.  
  1057.           [c:\] copy a:*.dat c:\mydir\
  1058.           [c:\] copy a:*.dat c:\data
  1059.  
  1060.  When you copy to a directory, if you add a backslash [\] to the end of the 
  1061.  name as shown in the first example above, COPY will display an error message 
  1062.  if the name does not refer to an existing directory.  You can use this feature 
  1063.  to keep COPY from treating a mistyped destination directory name as a file 
  1064.  name and attempting to append all your source files to a destination file, 
  1065.  when you really meant to copy them individually to a destination directory. 
  1066.  
  1067.  A plus [+] tells COPY to append two or more files to a single+destination 
  1068.  file.  If you list several source files separated with [+] and don't specify a 
  1069.  destination, COPY will use the name of the first source file as the 
  1070.  destination, and append each subsequent file to the first file.  In this case 
  1071.  the destination file will always be created in the current directory, even if 
  1072.  the first source file is in another directory or on another drive. 
  1073.  
  1074.  For example, the following command will append the contents of C:\MEMO2 and 
  1075.  C:\MEMO3 to C:\MEMO1 and leave the combined contents in the file named 
  1076.  C:\MEMO1: 
  1077.  
  1078.           [c:\] copy memo1+memo2+memo3
  1079.  
  1080.  To append the same three files but store the result in BIGMEMO: 
  1081.  
  1082.           [c:\] copy memo1+memo2+memo3 bigmemo
  1083.  
  1084.  To append C:\MEM\MEMO2 and C:\MEM\MEMO3 to D:\DATA\MEMO1, and leave the result 
  1085.  in C:\MEM\MEMO1: 
  1086.  
  1087.           [c:\mem] copy d:\data\memo1+memo2+memo3
  1088.  
  1089.  You cannot append files to a device (such as a printer); if you try to do so, 
  1090.  COPY will ignore the [+] signs and copy the files individually. If you attempt 
  1091.  to append several+source files to a destination directory or disk, COPY will 
  1092.  append the files and place the copy in the new location with the same name as 
  1093.  the first source file. 
  1094.  
  1095.  If your destination has wildcards in it, COPY will attempt to match them with 
  1096.  the source names.  For example, this command copies the .DAT files from drive 
  1097.  A to C:\MYDIR and gives the new copies the extension .DX: 
  1098.  
  1099.           [c:\] copy a:*.dat c:\mydir\*.dx
  1100.  
  1101.  This feature can give you unexpected results if you use it with multiple 
  1102.  source file names.  For example, suppose that drive A contains XYZ.DAT and 
  1103.  XYZ.TXT.  The command 
  1104.  
  1105.           [c:\] copy a:\*.dat a:\*.txt c:\mydir\*.dx
  1106.  
  1107.  will copy A:XYZ.DAT to C:\MYDIR\XYZ.DX.  Then it will copy A:XYZ.TXT to 
  1108.  C:\MYDIR\XYZ.DX, overwriting the first file it copied. 
  1109.  
  1110.  COPY also understands include lists, so you can specify several different 
  1111.  kinds of files in the same command. This command copies the .TXT, .DOC, and 
  1112.  .BAT files from the E:\MYDIR directory to the root directory of drive A: 
  1113.  
  1114.           [c:\] copy e:\mydir\*.txt;*.doc;*.bat a:\
  1115.  
  1116.  You can use date, time, and size ranges  to further define the files that you 
  1117.  want to copy.  This example copies every file in the E:\MYDIR directory, which 
  1118.  was created or modified yesterday, and which is also 10,000 bytes or smaller 
  1119.  in size, to the root directory of drive A: 
  1120.  
  1121.           [c:\] copy /[d-1] /[s0,10000] e:\mydir\*.* a:\
  1122.  
  1123.  COPY maintains the hidden and system attributes of files, but not the 
  1124.  read-only attribute.  The destination file will always have the archive 
  1125.  attribute set. 
  1126.  
  1127.  If you COPY files with long filenames to a volume which does not support them, 
  1128.  Take Command will display an error message. 
  1129.  
  1130.  Options: 
  1131.  
  1132.     The /A(SCII) and /B(inary) options apply to the preceding filename and to 
  1133.     all subsequent filenames on the command line until the file name preceding 
  1134.     the next /A or /B, if any. The other options (/A:, /C, /H, /M, /N, /P, /Q, 
  1135.     /R, /S, /T, /U, /V) apply to all filenames on the command line, no matter 
  1136.     where you put them.  For example, either of the following commands could be 
  1137.     used to copy a font file to the printer in binary mode: 
  1138.  
  1139.                 [c:\] copy /b myfont.dat prn
  1140.                 [c:\] copy myfont.dat /b prn
  1141.  
  1142.     Some options do not make sense in certain contexts, in which case COPY will 
  1143.     ignore them.  For example, you cannot prompt before replacing an existing 
  1144.     file when the destination is a device such as the printer -- there's no 
  1145.     such thing as an "existing file" on the printer.  If you use conflicting 
  1146.     output options, like /Q and /P, COPY will take a "conservative" approach 
  1147.     and give priority to the option which generates more prompts or more 
  1148.     information. 
  1149.  
  1150.     /A      (ASCII) If you use /A with a source filename, the file will be 
  1151.             copied up to, but not including, the first Ctrl-Z (Control-Z or 
  1152.             ASCII 26) character in the file.  If you use /A with a destination 
  1153.             filename, a Ctrl-Z will be added to the end of the file (some 
  1154.             application programs use the Ctrl-Z to mark the end of a file). /A 
  1155.             is the default when appending files, or when the destination is a 
  1156.             device like NUL or PRN, rather than a disk file. 
  1157.  
  1158.     /A      (Attribute select):  Select only those files that have the 
  1159.             specified attribute(s) set.  Preceding the attribute character with 
  1160.             a hyphen [-] will select files that do not have that attribute set. 
  1161.             The colon [:] after /A is required.  The attributes are: 
  1162.  
  1163.                          R  Read-only 
  1164.                          H  Hidden 
  1165.                          S  System 
  1166.                          D  Subdirectory 
  1167.                          A  Archive 
  1168.  
  1169.             If no attributes are listed at all (e.g., COPY /A:), COPY will 
  1170.             select all files and subdirectories including hidden and system 
  1171.             files (this is equivalent to COPY /H).  If attributes are combined, 
  1172.             all the specified attributes must match for a file to be selected. 
  1173.             For example, /A:RHS will select only those files with all three 
  1174.             attributes set. 
  1175.  
  1176.     /B      (Binary) If you use /B with a source filename, the entire file is 
  1177.             copied; Ctrl-Z characters in the file do not affect the copy 
  1178.             operation.  Using /B with a destination filename prevents addition 
  1179.             of a Ctrl-Z to the end of the destination file. /B is the default 
  1180.             for normal file copies. 
  1181.  
  1182.     /C      (Changed files) Copy files only if the destination file exists and 
  1183.             is older than the source (see also /U).  This option is useful for 
  1184.             updating the files in one directory from those in another without 
  1185.             copying any newly created files. 
  1186.  
  1187.     /H      (Hidden) Copy all matching files including those with the hidden 
  1188.             and/or system attribute set. 
  1189.  
  1190.     /M      (Modified) Copy only those files with the archive attribute set, 
  1191.             i.e., those which have been modified since the last backup.  The 
  1192.             archive attribute will not be cleared after copying. 
  1193.  
  1194.     /N      (Nothing) Do everything except actually perform the copy. This 
  1195.             option is useful for testing what the result of a complex COPY 
  1196.             command will be. 
  1197.  
  1198.     /P      (Prompt) Ask the user to confirm each source file.  Your options at 
  1199.             the prompt are explained in detail under Page and File Prompts. 
  1200.  
  1201.     /Q      (Quiet) Don't display filenames or the total number of files 
  1202.             copied.  This option is most often used in batch files.  See also 
  1203.             /T. 
  1204.  
  1205.     /R      (Replace) Prompt the user before overwriting an existing file. 
  1206.             Your options at the prompt are explained in detail under Page and 
  1207.             File Prompts. 
  1208.  
  1209.     /S      (Subdirectories) Copy the subdirectory tree starting with the files 
  1210.             in the source directory plus each subdirectory below that.  The 
  1211.             destination must be a directory; if it doesn't exist, COPY will 
  1212.             attempt to create it.  COPY will also attempt to create needed 
  1213.             subdirectories on the tree below the destination, including empty 
  1214.             source directories.  If you attempt to use COPY /S to copy a 
  1215.             subdirectory tree into part of itself, COPY will display an error 
  1216.             message and exit. 
  1217.  
  1218.     /T      (Totals) Turns off the display of filenames, like /Q, but does 
  1219.             display the total number of files copied. 
  1220.  
  1221.     /U      (Update) Copy each source file only if it is newer than a matching 
  1222.             destination file or if a matching destination file does not exist 
  1223.             (see also /C). This option is useful for keeping one directory 
  1224.             matched with another with a minimum of copying. 
  1225.  
  1226.     /V      (Verify) Verify each disk write.  This is the same as executing the 
  1227.             VERIFY ON command, but is only active during the COPY. /V does not 
  1228.             read back the file and compare its contents with what was written; 
  1229.             it only verifies that the data written to disk is physically 
  1230.             readable. 
  1231.  
  1232.  
  1233. ΓòÉΓòÉΓòÉ 3.14. DATE - Set the date ΓòÉΓòÉΓòÉ
  1234.  
  1235.  Purpose:    Display and optionally change the system date. 
  1236.  
  1237.  Format:     DATE [mm -dd -yy ] 
  1238.  
  1239.              mm :  The month (1 - 12). 
  1240.              dd :  The day (1 - 31). 
  1241.              yy :  The year (80 - 99 = 1980 - 1999, or a 4- digit year). 
  1242.  
  1243.  See also:  TIME. 
  1244.  
  1245.  Usage: 
  1246.  
  1247.  If you simply type DATE without any parameters, you will see the current 
  1248.  system date and time, and be prompted for a new date. Press Enter if you don't 
  1249.  wish to change the date.  If you type a new date, it will become the current 
  1250.  system date, which is included in the directory entry for each file as it is 
  1251.  created or altered: 
  1252.  
  1253.           [c:\] date
  1254.           Wed  Jan 3, 1996  9:30:06
  1255.           Enter new date (mm-dd-yy):
  1256.  
  1257.  You can also enter a new system date by typing the DATE command plus the new 
  1258.  date on the command line: 
  1259.  
  1260.           [c:\] date 4-1-96
  1261.  
  1262.  You can use hyphens, slashes, or periods to separate the month, day, and year 
  1263.  entries.  A full 4-digit year can be entered if you wish. 
  1264.  
  1265.  DATE adjusts the format it expects depending on your country settings. When 
  1266.  entering the date, use the correct format for the country setting currently in 
  1267.  effect on your system. 
  1268.  
  1269.  
  1270. ΓòÉΓòÉΓòÉ 3.15. DEL - Delete files ΓòÉΓòÉΓòÉ
  1271.  
  1272.  Purpose:    Erase one file, a group of files, or entire subdirectories. 
  1273.  
  1274.  Format:     DEL [/A:[[-]rhsda] /F /N /P /Q /S /T /X /Y /Z] file... 
  1275.                 or 
  1276.              ERASE [/A:[[-]rhsda] /F /N /P /Q /S /T /X /Y /Z] file... 
  1277.  
  1278.              file :  The file, subdirectory, or list of files or subdirectories 
  1279.              to erase. 
  1280.  
  1281.              /A:(ttribute select)            /S(ubdirectories) 
  1282.              /F(orce delete)                 /T(otal) 
  1283.              /N(othing)                      /X (remove empty subdirectories) 
  1284.              /P(rompt)                       /Y(es to all prompts) 
  1285.              /Q(uiet)                        /Z(ap hidden and read-only files) 
  1286.  
  1287.  File Selection: 
  1288.  
  1289.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  1290.  
  1291.  Usage: 
  1292.  
  1293.  DEL and ERASE are synonyms; you can use either one. 
  1294.  
  1295.  Use the DEL and ERASE commands with caution; the files and subdirectories that 
  1296.  you erase may be impossible to recover without specialized utilities and a lot 
  1297.  of work. 
  1298.  
  1299.  To erase a single file, simply enter the file name: 
  1300.  
  1301.           [c:\] del letters.txt
  1302.  
  1303.  You can also erase multiple files in a single command.  For example, to erase 
  1304.  all the files in the current directory with a .BAK or .PRN extension: 
  1305.  
  1306.           [c:\] del *.bak *.prn
  1307.  
  1308.  If you enter a subdirectory name, or a filename composed only of wildcards (* 
  1309.  and/or ?), DEL asks for confirmation (Y or N) unless you specified the /Y 
  1310.  option.  If you respond with a Y, DEL will delete all the files in that 
  1311.  subdirectory (hidden, system, and read-only files are only deleted if you use 
  1312.  the /Z option). 
  1313.  
  1314.  DEL displays the amount of disk space recovered, unless the /Q option is used 
  1315.  (see below).  It does so by comparing the amount of free disk space before and 
  1316.  after the DEL command is executed.  This amount may be incorrect if you are 
  1317.  using a deletion tracking system which stores deleted files in a hidden 
  1318.  directory, or if another program performs a file operation while the DEL 
  1319.  command is executing. 
  1320.  
  1321.  Remember that DEL removes file descriptions along with files.  Most deletion 
  1322.  tracking systems will not be able to save or recover a file's description, 
  1323.  even if they can save or recover the data in a file. 
  1324.  
  1325.  DEL returns a non-zero exit code if no files are deleted, or if another error 
  1326.  occurs.  You can test this exit code with the %_? environment variable, and 
  1327.  use it with conditional commands (&& and ||). 
  1328.  
  1329.  Options: 
  1330.  
  1331.     /A      (Attribute select):  Select only those files that have the 
  1332.             specified attribute(s) set.  Preceding the attribute character with 
  1333.             a hyphen [-] will select files that do not have that attribute set. 
  1334.             The colon [:] after /A is required.  The attributes are: 
  1335.  
  1336.                          R  Read-only 
  1337.                          H  Hidden 
  1338.                          S  System 
  1339.                          D  Subdirectory 
  1340.                          A  Archive 
  1341.  
  1342.             If no attributes are listed at all (e.g., DEL /A), DEL will delete 
  1343.             all files and subdirectories including hidden and system files.  If 
  1344.             attributes are combined, all the specified attributes must match 
  1345.             for a file to be selected for deletion.  For example, /A:RHS will 
  1346.             select only those files with all three attributes set. 
  1347.  
  1348.     /N      (Nothing) Do everything except actually delete the file(s).  This 
  1349.             is useful for testing what the result of a DEL would be. 
  1350.  
  1351.     /P      (Prompt) Prompt the user to confirm each erasure.  Your options at 
  1352.             the prompt are explained in detail under Page and File Prompts. 
  1353.  
  1354.     /Q      (Quiet) Don't display filenames as they are deleted, or the number 
  1355.             of files deleted or bytes freed.  See also /T. 
  1356.  
  1357.     /S      (Subdirectories) Delete the specified files in this directory and 
  1358.             all of its subdirectories.  This is like a GLOBAL DEL, and can be 
  1359.             used to delete all the files in a subdirectory tree or even a whole 
  1360.             disk. It should be used with caution! 
  1361.  
  1362.     /T      (Total) Don't display filenames as they are deleted, but display 
  1363.             the total number of files deleted plus the amount of free disk 
  1364.             space recovered. 
  1365.  
  1366.     /X      (Remove empty subdirectories) Remove empty subdirectories after 
  1367.             deleting (only useful when used with /S). 
  1368.  
  1369.     /Y      (Yes) The reverse of /P -- it assumes a Y response to everything, 
  1370.             including deleting an entire subdirectory tree. Take Command 
  1371.             normally prompts before deleting files when the name consists only 
  1372.             of wildcards or a subdirectory name (see above); /Y overrides this 
  1373.             protection, and should be used with extreme caution! 
  1374.  
  1375.     /Z      (Zap) Delete read-only, hidden, and system files as well as normal 
  1376.             files.  Files with the read-only, hidden, or system attribute set 
  1377.             are normally protected from deletion; /Z overrides this protection, 
  1378.             and should be used with caution.  Because EXCEPT works by hiding 
  1379.             files, /Z will override an EXCEPT command. 
  1380.  
  1381.             For example, to delete the entire subdirectory tree starting with 
  1382.             C:\UTIL, including hidden and read-only files, without prompting 
  1383.             (use this command with CAUTION!): 
  1384.  
  1385.                                 [c:\] del /sxyz c:\util\
  1386.  
  1387.  
  1388. ΓòÉΓòÉΓòÉ 3.16. DELAY - Pause for a specified time ΓòÉΓòÉΓòÉ
  1389.  
  1390.  Purpose:    Pause for a specified length of time. 
  1391.  
  1392.  Format:     DELAY [seconds ] 
  1393.  
  1394.              seconds :  The number of seconds to delay. 
  1395.  
  1396.  Usage: 
  1397.  
  1398.  DELAY is useful in batch file loops while waiting for something to occur.  To 
  1399.  wait for 10 seconds: 
  1400.  
  1401.           delay 10
  1402.  
  1403.  A simple loop could make a tone with the BEEP command to get the operator's 
  1404.  attention and then DELAY for a few seconds while waiting for the user to 
  1405.  respond. 
  1406.  
  1407.  For delays shorter than one second, use the BEEP command with an inaudible 
  1408.  frequency (below 20 Hz). 
  1409.  
  1410.  You can cancel a delay by pressing Ctrl-C or Ctrl-Break. 
  1411.  
  1412.  
  1413. ΓòÉΓòÉΓòÉ 3.17. DESCRIBE - Create file description ΓòÉΓòÉΓòÉ
  1414.  
  1415.  Purpose:    Create, modify, or delete file and subdirectory descriptions. 
  1416.  
  1417.  Format:     DESCRIBE [/A:[[-]rhsda]] file ["description" ] ... 
  1418.  
  1419.              file :  The file or files to operate on. 
  1420.              "description" :  The description to attach to the file. 
  1421.  
  1422.              /A:(ttribute select) 
  1423.  
  1424.  File Selection: 
  1425.  
  1426.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  1427.  
  1428.  Usage: 
  1429.  
  1430.  DESCRIBE adds descriptions to files and subdirectories. The descriptions are 
  1431.  displayed by DIR in single-column mode and by SELECT. Descriptions let you 
  1432.  identify your files in much more meaningful ways than you can in an 
  1433.  eight-character filename. 
  1434.  
  1435.  You enter a description on the command line by typing the DESCRIBE command, 
  1436.  the filename, and the description in quotation marks, like this: 
  1437.  
  1438.           [c:\] describe memo.txt "Memo to Bob about party"
  1439.  
  1440.  If you don't put a description on the command line, DESCRIBE will prompt you 
  1441.  for it: 
  1442.  
  1443.           [c:\] describe memo.txt
  1444.  
  1445.   Describe "memo.txt" : Memo to Bob about party
  1446.  
  1447.  If you use wildcards or multiple filenames with the DESCRIBE command and don't 
  1448.  include the description text, you will be prompted to enter a description for 
  1449.  each file.  If you do include the description on the command line, all 
  1450.  matching files will be given the same description. 
  1451.  
  1452.  Each description can be up to 511 characters long.  You can change this limit 
  1453.  with the DescriptionMax directive in TCMDOS2.INI.  DESCRIBE can edit 
  1454.  descriptions longer than DescriptionMax, but will not allow you to lengthen 
  1455.  the existing text. 
  1456.  
  1457.  The descriptions are stored in each directory in a hidden file called 
  1458.  DESCRIPT.ION.  Use the ATTRIB command to remove the hidden attribute from this 
  1459.  file if you need to copy or delete it.  (DESCRIPT.ION is always created as a 
  1460.  hidden file, but will not be re-hidden by Take Command if you remove the 
  1461.  hidden attribute.)  You can change the description file name with the 
  1462.  INI_DescriptionName directive in the TCMDOS2.INI file or the SETDOS command, 
  1463.  and retrieve it with the _DNAME internal variable. 
  1464.  
  1465.  The description file is modified appropriately whenever you perform an 
  1466.  internal command which affects it (such as COPY, MOVE, DEL, or RENAME), but 
  1467.  not if you use an external program (such as XCOPY or a visual shell). 
  1468.  
  1469.  On drives which support long filenames you will not see file descriptions in a 
  1470.  normal DIR display, because of the potential length of each filename. To view 
  1471.  the descriptions, use DIR /Z to display the directory in FAT format.  See the 
  1472.  DIR command for more details. 
  1473.  
  1474.  Options: 
  1475.  
  1476.     /A      (Attribute select):  Select only those files that have the 
  1477.             specified attribute(s) set.  Preceding the attribute character with 
  1478.             a hyphen [-] will select files that do not have that attribute set. 
  1479.             The colon [:] after /A is required.  The attributes are: 
  1480.  
  1481.                          R  Read-only 
  1482.                          H  Hidden 
  1483.                          S  System 
  1484.                          D  Subdirectory 
  1485.                          A  Archive 
  1486.  
  1487.             If no attributes are listed at all (e.g., /A), DESCRIBE will select 
  1488.             all files and subdirectories including hidden and system files.  If 
  1489.             attributes are combined, all the specified attributes must match 
  1490.             for a file to be selected.  For example, /A:RHS will select only 
  1491.             those files with all three attributes set. 
  1492.  
  1493.  
  1494. ΓòÉΓòÉΓòÉ 3.18. DETACH - Start a program in "detached" mode ΓòÉΓòÉΓòÉ
  1495.  
  1496.  Purpose:    Start an OS/2 program in "detached" mode. 
  1497.  
  1498.  Format:     DETACH command 
  1499.  
  1500.              command :  The name of a command to execute, including an optional 
  1501.              drive and path specification. 
  1502.  
  1503.  See also:  START. 
  1504.  
  1505.  Usage: 
  1506.  
  1507.  When you start a program with DETACH, that program normally cannot use the 
  1508.  keyboard, mouse, or video display.  It is "detached" from the normal means of 
  1509.  user input and output.  However, you can redirect the program's standard I/O 
  1510.  to other devices if necessary, using redirection symbols. 
  1511.  
  1512.  The command can be an internal command, external command, alias, or batch 
  1513.  file.  If it is not an external command, Take Command will detach a copy of 
  1514.  itself to execute the command. 
  1515.  
  1516.  For example, the following command will detach a copy of Take Command to run 
  1517.  the batch file XYZ.BTM: 
  1518.  
  1519.           [c:\] detach xyz.btm
  1520.  
  1521.  Once the program has started, Take Command returns to the prompt immediately. 
  1522.  It does not wait for a detached program to finish. 
  1523.  
  1524.  Due to limitations in the way OS/2 starts detached processes, Take Command 
  1525.  cannot perform a true detach operation like that available from a 
  1526.  character-mode command processor such as 4OS2 or CMD.EXE.  Instead, it starts 
  1527.  the program in an invisible window.  If you require a true detached process 
  1528.  you must use a character-mode command processor to start it. 
  1529.  
  1530.  
  1531. ΓòÉΓòÉΓòÉ 3.19. DIR - Display directories ΓòÉΓòÉΓòÉ
  1532.  
  1533.  Purpose:    Display information about files and subdirectories. 
  1534.  
  1535.  Format:     DIR [/1 /2 /4 /A[[:][-]rhsda] /B /D /E /F /H /I"text" /J /K /L /M 
  1536.              /N /O[[:][-]adeginrsu] /P /R /S /T[:acw] /U /V /W /Z] [file...] 
  1537.  
  1538.              file :  The file, directory, or list of files or directories to 
  1539.              display. 
  1540.  
  1541.              /1 (one column)                 /L(ower case) 
  1542.              /2 (two columns)                /M (suppress footer) 
  1543.              /4 (four columns)               /N(ew format) 
  1544.              /A(ttribute select)             /O(rder) 
  1545.              /B(are)                         /P(ause) 
  1546.              /D(isable color coding)         /R (disable wRap) 
  1547.              /E (use upper case)             /S(ubdirectories) 
  1548.              /F(ull path)                    /T (aTtribute) or (Time) 
  1549.              /H(ide dots)                    /U (sUmmary information) 
  1550.              /I (match descriptions)         /V(ertical sort) 
  1551.              /J(ustify names)                /W(ide) 
  1552.              /K (suppress header)            /Z (use FAT format) 
  1553.  
  1554.  See also:  ATTRIB, DESCRIBE, SELECT, and SETDOS. 
  1555.  
  1556.  File Selection: 
  1557.  
  1558.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  1559.  
  1560.  Usage: 
  1561.  
  1562.  DIR can be used to display information about files from one or more of your 
  1563.  disk directories, in a wide range of formats.  Depending on the options 
  1564.  chosen, you can display the file name, attributes, and size; the time and date 
  1565.  of the last change to the file; and the file description. You can also display 
  1566.  information in 1, 2, 4, or 5 columns, sort the files several different ways, 
  1567.  use color to distinguish file types, and pause after each full screen. 
  1568.  
  1569.  The various DIR displays are controlled through options or switches. The best 
  1570.  way to learn how to use the many options available with the DIR command is to 
  1571.  experiment.  You will soon know which options you want to use regularly.  You 
  1572.  can select those options permanently by using the ALIAS command. 
  1573.  
  1574.  On drives which support long file names, DIR will use the standard long name 
  1575.  display format with the filename at the right-hand side of the display. File 
  1576.  descriptions are not displayed in this format.  To switch to the more 
  1577.  traditional "FAT" (short name) format, and display the file descriptions, use 
  1578.  the /Z switch. 
  1579.  
  1580.  You may want to mix several options.  For example, to display all the files in 
  1581.  the current directory, in 2 columns, sorted vertically (down one column then 
  1582.  down the next), and with a pause at the end of each page: 
  1583.  
  1584.           [c:\] dir /2/p/v
  1585.  
  1586.  To set up this format as the default, using an alias: 
  1587.  
  1588.           [c:\] alias dir=*dir /2/p/v
  1589.  
  1590.  This example displays all the files on all directories of drive C, including 
  1591.  hidden and system files, pausing after each page: 
  1592.  
  1593.           [c:\] dir /s/a/p c:\
  1594.  
  1595.  DIR allows wildcard characters (* and ?) in the filename.  If you don't 
  1596.  specify a filename, DIR defaults to *.* (display all non- hidden files and 
  1597.  subdirectories in the current directory).  To display all of the .WKS files in 
  1598.  the current directory: 
  1599.  
  1600.           [c:\] dir *.wks
  1601.  
  1602.  With the /I option, DIR can select files to display based on their 
  1603.  descriptions. DIR will display a file if its description matches the text 
  1604.  after the /I switch.  The search is not case sensitive. You can use wildcards 
  1605.  and extended wildcards as part of the text.  For example, to display any file 
  1606.  described as a "Test File" you can use this command: 
  1607.  
  1608.           [c:\] dir /i"test file"
  1609.  
  1610.  If you want to display files that include the words "test file" anywhere in 
  1611.  their descriptions, use extended wild cards like this: 
  1612.  
  1613.           [c:\] dir /i"*test file*"
  1614.  
  1615.  If you link two or more filenames together with spaces, DIR will display all 
  1616.  of the files that match the first name and then all of the files that match 
  1617.  the second name. You may use a different drive and path for each filename. 
  1618.  This example lists all of the .WKS and then all of the .WK1 files in the 
  1619.  current directory: 
  1620.  
  1621.           [c:\] dir *.wks *.wk1
  1622.  
  1623.  Filenames are normally displayed in lower case for FAT drives, and in the case 
  1624.  in which they are stored on the disk for HPFS drives.  You can override these 
  1625.  defaults and force filenames to display in upper case with /E, or in lower 
  1626.  case with /L. 
  1627.  
  1628.  If you use an include list to link multiple filenames, DIR will display the 
  1629.  matching filenames in a single listing.  Only the first filename in an include 
  1630.  list can have a path; the other files must be in the same path.  This example 
  1631.  displays the same files as the previous example, but the .WKS and .WK1 files 
  1632.  are intermixed: 
  1633.  
  1634.           [c:\] dir *.wks;*.wk1
  1635.  
  1636.  You can display the file and subdirectory names in color by setting the 
  1637.  COLORDIR environment variable or using the ColorDir directive in your .INI 
  1638.  file.  See Color-Coded Directories for details. 
  1639.  
  1640.  If you are using color-coded directories and attempt to redirect the output of 
  1641.  DIR to a character device, such as a serial port or the printer, 
  1642.  non-color-coded file names will be displayed on the device but color-coded 
  1643.  names may still be displayed on the screen. This will not occur if the output 
  1644.  of DIR is redirected to a disk file.  To prevent this problem, use the /D 
  1645.  switch to disable color coding when redirecting the output of DIR to a 
  1646.  character device. 
  1647.  
  1648.  When displaying file descriptions, DIR will wrap long lines to fit on the 
  1649.  screen.  DIR displays a maximum of 40 characters of text in each line of a 
  1650.  description, unless your screen width allows a wider display.  If you disable 
  1651.  description wrapping with the /R switch, the description is truncated at the 
  1652.  right edge of the screen, and a right arrow is added at the end of the line to 
  1653.  alert you to the existence of additional description text. 
  1654.  
  1655.  If you attempt to redirect the output of DIR to a character device, such as a 
  1656.  serial port or the printer, long descriptions will be wrapped at the screen 
  1657.  width in the redirected output.  If this is not what you want, use /R to 
  1658.  disable wrapping. 
  1659.  
  1660.  When sorting file names and extensions, Take Command normally assumes that 
  1661.  sequences of digits should be sorted numerically (for example, the file DRAW2 
  1662.  would come before DRAW03 because 2 is numerically smaller than 03), rather 
  1663.  than strictly alphabetically (where DRAW2 would come second because "2" is 
  1664.  after "0" in alphanumeric order). You can defeat this behavior and force a 
  1665.  strict alphabetic sort with the /O:a option. 
  1666.  
  1667.  If you have selected a specific country code for your system, DIR will display 
  1668.  the date in the format for that country.  The default date format is U.S. 
  1669.  (mm-dd-yy).  The separator character in the file time will also be affected by 
  1670.  the country code.  If a file's date and time is set to exactly zero, it will 
  1671.  be displayed as blank. 
  1672.  
  1673.  DIR can handle directories of any size, limited only by available memory. 
  1674.  Memory requirements for DIR are generally not a concern under Take Command, 
  1675.  because of the virtual memory available under this operating system. 
  1676.  
  1677.  Options on the command line apply only to the filenames which follow the 
  1678.  option, and options at the end of the line apply to the preceding filename 
  1679.  only.  This allows you to specify different options for different groups of 
  1680.  files, yet retains compatibility with the traditional DIR command when a 
  1681.  single filename is specified. 
  1682.  
  1683.  Options: 
  1684.  
  1685.     /1      Single column display - display the filename, size, date, time, and 
  1686.             (if the drive does not support long filenames) the description. 
  1687.  
  1688.     /2      Two column display -- display the filename, size, date, and time. 
  1689.             If you use /2 (or /4) on a drive which supports long filenames, DIR 
  1690.             will only display the file names.  Also, the number of columns may 
  1691.             be reduced to one for names too long to fit on half the screen. 
  1692.             Due to these restrictions, /2 is normally most useful on drives 
  1693.             which support long filenames when used with /Z to force the display 
  1694.             to FAT format. 
  1695.  
  1696.     /4      Four column display -- display the filename and size, in K ( 
  1697.             kilobytes) or M (megabytes).  The note under /2 above regarding 
  1698.             drives which support long filenames applies to /4 as well. 
  1699.  
  1700.     /A      (Attribute select):  Select only those files that have the 
  1701.             specified attribute(s) set.  Preceding the attribute character with 
  1702.             a hyphen [-] will select files that do not have that attribute set. 
  1703.             The colon [:] after /A is optional.  The attributes are: 
  1704.  
  1705.                          R  Read-only 
  1706.                          H  Hidden 
  1707.                          S  System 
  1708.                          D  Subdirectory 
  1709.                          A  Archive 
  1710.  
  1711.             If no attributes are listed at all (e.g., DIR /A), DIR will display 
  1712.             all files and subdirectories including hidden and system files.  If 
  1713.             attributes are combined, all the specified attributes must match 
  1714.             for a file to be included in the listing.  For example, /A:RHS will 
  1715.             display only those files with all three attributes set. 
  1716.  
  1717.     /B      (Bare)  Suppress the header and summary lines, and display file or 
  1718.             subdirectory names only, in a single column. This option is most 
  1719.             useful when you want to redirect a list of names to a file or 
  1720.             another program.  If you use /B with /S, DIR will show the full 
  1721.             path of each file instead of simply its name and extension. 
  1722.  
  1723.     /D      (Disable color coding)  Temporarily disable directory color coding. 
  1724.             May be required when color-coded directories are used and DIR 
  1725.             output is redirected to a character device like the printer (e.g., 
  1726.             PRN or LPT1) or serial port (e.g., COM1 or COM2).  /D is not 
  1727.             required when DIR output is redirected to a file. 
  1728.  
  1729.     /E      Display filenames in upper case; also see SETDOS /U and the 
  1730.             UpperCase directive in TCMDOS2.INI. 
  1731.  
  1732.     /F      (Full path)  Display each filename with its drive letter and path 
  1733.             in a single column, without other information. 
  1734.  
  1735.     /H      (Hide dots)  Suppress the display of the "." and ".." directories. 
  1736.  
  1737.     /I      Display filenames by matching text in their descriptions. The text 
  1738.             can include wild cards and extended wildcards.  The search text 
  1739.             must be enclosed in quotation marks. /I may be used to select files 
  1740.             even if descriptions are not displayed (for example, if /2 is 
  1741.             used).  However, /I will be ignored if /C or /O:c is used. 
  1742.  
  1743.     /J      (Justify names)  Justify (align) filename extensions and display 
  1744.             them in the traditional format. 
  1745.  
  1746.     /K      Suppress the header (disk and directory name) display. 
  1747.  
  1748.     /L      (Lower case)  Display file and directory names in lower case; also 
  1749.             see SETDOS /U and the UpperCase directive in TCMDOS2.INI. 
  1750.  
  1751.     /M      Suppress the footer (file and byte count totals) display. 
  1752.  
  1753.     /N      (New format) Use the long filename display format, even if the 
  1754.             files are stored on a volume which does not support long filenames. 
  1755.             See also /Z. 
  1756.  
  1757.     /O      (Order) Set the sorting order.  You may use any combination of the 
  1758.             following sorting options; if multiple options are used, the 
  1759.             listing will be sorted with the first sort option as the primary 
  1760.             key, the next as the secondary key, and so on: 
  1761.  
  1762.                      -  Reverse the sort order for the next option 
  1763.                      a  Sort in ASCII order, not numerically, when there are 
  1764.                      digits in the name 
  1765.                      d  Sort by date and time (oldest first); for HPFS drives 
  1766.                      also see /T 
  1767.                      e  Sort by extension 
  1768.                      g  Group subdirectories first, then files 
  1769.                      i  Sort by file description (ignored if /C or /O:c is 
  1770.                      used) 
  1771.                      n  Sort by filename (this is the default) 
  1772.                      r  Reverse the sort order for all options 
  1773.                      s  Sort by size 
  1774.                      u  Unsorted 
  1775.  
  1776.     /P      (Pause)  Wait for a key to be pressed after each screen page before 
  1777.             continuing the display.  Your options at the prompt are explained 
  1778.             in detail under Page and File Prompts. 
  1779.  
  1780.     /R      (disable wRap)  Forces long descriptions to be displayed on a 
  1781.             single line, rather than wrapped onto two or more lines.  Use /R 
  1782.             when output is redirected to a character device, such as a serial 
  1783.             port or the printer; or when you want descriptions truncated, 
  1784.             rather than wrapped, in the on-screen display. 
  1785.  
  1786.     /S      (Subdirectories)  Display file information from the current 
  1787.             directory and all of its subdirectories.  DIR will only display 
  1788.             headers and summaries for those directories which contain files 
  1789.             that match the filename(s) and attributes (if /A is used) that you 
  1790.             specify on the command line. 
  1791.  
  1792.     /T      (aTtribute display)  Display the filenames, attributes, and 
  1793.             descriptions.  The descriptions will be wrapped onto the next line, 
  1794.             if necessary, unless you also use the /R (truncate) option.  If you 
  1795.             use both /T and /R, descriptions are truncated after 34 characters 
  1796.             on an 80-column display.  The attributes are displayed in the 
  1797.             format RHSA, with the following meanings: 
  1798.  
  1799.                          R  Read-only 
  1800.                          H  Hidden 
  1801.                          S  System 
  1802.                          A  Archive 
  1803.  
  1804.             If you wish to add another option after /T, you must start the next 
  1805.             option with a forward slash.  If you don 't, Take Command will 
  1806.             interpret the /T as the /T:acw time display switch (see below) and 
  1807.             the following character as a valid or invalid time selector.  For 
  1808.             example: 
  1809.  
  1810.                                 [c:\] dir /tz       incorrect, will display error
  1811.                                 [c:\] dir /t/z      correct
  1812.  
  1813.     /T:acw  (Time display)  Specify which of the date and time fields on a 
  1814.             drive which supports long filenames should be displayed and used 
  1815.             for sorting: 
  1816.  
  1817.                          a  Last access time 
  1818.                          c  Creation time 
  1819.                          w  Last write time (default) 
  1820.  
  1821.     /U      (sUmmary information)  Only display the number of files, the total 
  1822.             file size, and the total amount of disk space used. 
  1823.  
  1824.     /V      (Vertical sort)  Display the filenames sorted vertically rather 
  1825.             than horizontally (use with the /2, /4 or /W options). 
  1826.  
  1827.     /W      (Wide)  Display filenames only, horizontally across the screen (5 
  1828.             columns on an 80-character wide display). 
  1829.  
  1830.     /Z      Display the directory in FAT format.  Long filenames will be 
  1831.             truncated to 12 characters.  If the name is longer than 12 
  1832.             characters, it will be followed by a right arrow to show that one 
  1833.             or more characters have been truncated. 
  1834.  
  1835.  
  1836. ΓòÉΓòÉΓòÉ 3.20. DIRS - Display the directory stack ΓòÉΓòÉΓòÉ
  1837.  
  1838.  Purpose:    Display the current directory stack. 
  1839.  
  1840.  Format:     DIRS 
  1841.  
  1842.  Usage: 
  1843.  
  1844.  The PUSHD command adds the current default drive and directory to the 
  1845.  directory stack, a list that Take Command maintains in memory.  The POPD 
  1846.  command removes the top entry of the directory stack and makes that drive and 
  1847.  directory the new default.  The DIRS command displays the contents of the 
  1848.  directory stack, with the most recent entries on top (i.e., the next POPD will 
  1849.  retrieve the first entry that DIRS displays). 
  1850.  
  1851.  The directory stack holds 255 characters, enough for 10 to 20 typical drive 
  1852.  and directory entries. 
  1853.  
  1854.  
  1855. ΓòÉΓòÉΓòÉ 3.21. DO - Loop in batch files ΓòÉΓòÉΓòÉ
  1856.  
  1857. DO 
  1858.  
  1859.  Purpose:    Create loops in batch files. 
  1860.  
  1861.  Format:     DO [n | FOREVER] 
  1862.                 or 
  1863.              DO varname = start TO end [BY n ] 
  1864.                 or 
  1865.              DO [WHILE | UNTIL] condition 
  1866.                 ... 
  1867.              [ITERATE] 
  1868.              [LEAVE] 
  1869.                 ... 
  1870.              ENDDO 
  1871.  
  1872.              n, start, end :  An integer between 0 and 2,147,483,647 inclusive, 
  1873.              or an internal variable or variable function that evaluates to 
  1874.              such a value. 
  1875.              varname :  The environment variable that will hold the loop 
  1876.              counter. 
  1877.              condition :  A test to determine if the loop should be executed. 
  1878.  
  1879.  Usage: 
  1880.  
  1881.  DO can only be used in batch files.  It cannot be used in aliases. 
  1882.  
  1883.  DO can be used to create 3 different kinds of loops.  The first, introduced by 
  1884.  DO n, is a counted loop.  The batch file lines between DO and ENDDO are 
  1885.  repeated n times.  You can also specify "forever" for n if you wish to create 
  1886.  an endless loop. For example: 
  1887.  
  1888.           do 5
  1889.           beep
  1890.           enddo
  1891.  
  1892.  The second type of loop is similar to a "for loop" in programming languages 
  1893.  like BASIC.  DO creates an environment variable, varname, and sets it equal to 
  1894.  the value start (if varname already exists in the environment, it will be 
  1895.  overwritten).  DO then begins the loop process by comparing the value of 
  1896.  varname with the value of end.  If varname is less than or equal to end, DO 
  1897.  executes the batch file lines up to the ENDDO.  Next, DO adds 1 to the value 
  1898.  of varname, or adds the value n if BY n is specified, and repeats the compare 
  1899.  and execute process until varname is greater than end. This example displays 
  1900.  the even numbers from 2 through 20: 
  1901.  
  1902.           do i = 2 to 20 by 2
  1903.           echo %i
  1904.           enddo
  1905.  
  1906.  DO can also count down, rather than up.  If n is negative, varname will 
  1907.  decrease by n with each loop, and the loop will stop when varname is less than 
  1908.  end. For example, to display the even numbers from 2 through 20 in reverse 
  1909.  order, replace the first line of the example above with: 
  1910.  
  1911.           do i = 20 to 2 by -2
  1912.  
  1913.  The third type of loop is called a "while loop" or "until loop." DO evaluates 
  1914.  the condition, which can be any of the tests supported by the IF command, and 
  1915.  executes the lines between DO and ENDDO as long as the condition is true.  The 
  1916.  loop ends when the condition becomes false. 
  1917.  
  1918.  WHILE tests the condition at the start of the loop; UNTIL tests it at the end. 
  1919.  If you use WHILE, the loop may never be executed (if the condition is false at 
  1920.  the start of the loop); if you use UNTIL, the loop will always be executed at 
  1921.  least once. 
  1922.  
  1923.  Two special commands, ITERATE and LEAVE, can only be used inside a DO / ENDDO 
  1924.  loop.  ITERATE ignores the remaining lines inside the loop and returns to the 
  1925.  beginning of loop for another iteration (unless DO determines that the loop is 
  1926.  finished).  LEAVE exits from the current DO loop and continues with the line 
  1927.  following ENDDO. Both ITERATE and LEAVE are most often used in an IF or IFF 
  1928.  command: 
  1929.  
  1930.           do while "%var" != "%val1"
  1931.           ...
  1932.           if "%var" == "%val2" leave
  1933.           enddo
  1934.  
  1935.  You can nest DO loops up to 15 levels deep. 
  1936.  
  1937.  The DO and ENDDO commands must be on separate lines, and cannot be placed 
  1938.  within a command group, or on the same line as other commands (this is the 
  1939.  reason DO cannot be used in aliases).  However, commands within the DO loop 
  1940.  can use command groups or the command separator in the normal way. 
  1941.  
  1942.  For example, the following command will not work properly, because the DO and 
  1943.  ENDDO are inside a command group and are not on separate lines: 
  1944.  
  1945.           if "%a" == "%b" (do i = 1 to 10 & echo %i & enddo)
  1946.  
  1947.  However this batch file fragment uses multiple commands and command grouping 
  1948.  within the DO, and will work properly: 
  1949.  
  1950.           do i = 1 to 10
  1951.           ...
  1952.           if "%x1" == "%x2" (echo Done! & leave)
  1953.           ...
  1954.           enddo
  1955.  
  1956.  You can exit from all DO / ENDDO loops by using GOTO to a line past the last 
  1957.  ENDDO.  However, be sure to read the cautionary notes about GOTO and DO under 
  1958.  the GOTO command before using a GOTO inside any DO loop. 
  1959.  
  1960.  
  1961. ΓòÉΓòÉΓòÉ 3.22. DPATH - Set data search path ΓòÉΓòÉΓòÉ
  1962.  
  1963.  Purpose:    Specify the subdirectories which applications will search to find 
  1964.              files that are not in the current directory. 
  1965.  
  1966.  Format:     DPATH [directory [;directory... ]] 
  1967.  
  1968.              directory :  The full name of a directory to include in the DPATH 
  1969.              (data path) setting. 
  1970.  
  1971.  See also:  PATH, SET, and ESET. 
  1972.  
  1973.  Usage: 
  1974.  
  1975.  When most OS/2 applications try to open a data file, they look for the file in 
  1976.  the current directory first.  If they fail to find the file there, they search 
  1977.  each of the directories in the DPATH setting in the order that they are 
  1978.  included.  Internal commands like TYPE do not search the DPATH directories for 
  1979.  files. 
  1980.  
  1981.  For example, the following DPATH command directs applications to look for 
  1982.  files in this order:  the current directory, the INIT directory on C, and the 
  1983.  CONFIG directory on D: 
  1984.  
  1985.           [c:\] dpath c:\init;d:\config
  1986.  
  1987.  The listing of directories to be searched can be set or viewed with DPATH. The 
  1988.  list is stored as an environment string with the variable name DPATH, and can 
  1989.  also be set or viewed with the SET command and edited with the ESET command. 
  1990.  
  1991.  Directory names in the DPATH must be separated with semicolons [;].  Take 
  1992.  Command will not shift directory names in the DPATH to upper case as it does 
  1993.  with those in the PATH setting.  If you want the names in the DPATH to be in 
  1994.  upper case you must enter them that way. 
  1995.  
  1996.  If you enter DPATH with no parameters, Take Command displays the current DPATH 
  1997.  search list. 
  1998.  
  1999.  
  2000. ΓòÉΓòÉΓòÉ 3.23. DRAWBOX - Draw a box ΓòÉΓòÉΓòÉ
  2001.  
  2002.  Purpose:    Draw a box on the screen. 
  2003.  
  2004.  Format:     DRAWBOX ulrow ulcol lrrow lrcol style [BRIght] fg ON [BRIght] bg 
  2005.              [FILL [BRIght] bgfill] [ZOOm] [SHAdow] 
  2006.  
  2007.              ulrow:  Row for upper left corner 
  2008.              ulcol:  Column for upper left corner 
  2009.              lrrow:  Row for lower right corner 
  2010.              lrcol:  Column for lower right corner 
  2011.              style:  Box drawing style: 
  2012.               0  No lines (box is drawn with blanks) 
  2013.               1  Single line 
  2014.               2  Double line 
  2015.               3  Single line on top and bottom, double on sides 
  2016.               4  Double line on top and bottom, single on sides 
  2017.              fg:  Foreground character color 
  2018.              bg:  Background character color 
  2019.              bgfill:  Background fill color (for the inside of the box) 
  2020.  
  2021.  See also:  DRAWHLINE and DRAWVLINE. 
  2022.  
  2023.  Usage: 
  2024.  
  2025.  DRAWBOX is useful for creating attractive screen displays in batch files. 
  2026.  
  2027.  For example, to draw a box around the entire screen with bright white lines on 
  2028.  a blue background: 
  2029.  
  2030.           drawbox 0 0 24 79 1 bri whi on blu fill blu
  2031.  
  2032.  See Colors and Color Names for details about colors. 
  2033.  
  2034.  If you use ZOOM, the box appears to grow in steps to its final size. The speed 
  2035.  of the zoom operation depends on the speed of your video system. 
  2036.  
  2037.  If you use SHADOW, a drop shadow is created by changing the characters in the 
  2038.  row under the box and the 2 columns to the right of the box to normal 
  2039.  intensity text with a black background (this will make characters displayed in 
  2040.  black disappear entirely). 
  2041.  
  2042.  The row and column values are zero-based, so on a standard 25 line by 80 
  2043.  column display, valid rows are 0 - 24 and valid columns are 0 - 79. 
  2044.  
  2045.  DRAWBOX checks for valid row and column values, and displays a "Usage" error 
  2046.  message if any values are out of range. 
  2047.  
  2048.  Unlike DRAWHLINE and DRAWVLINE, DRAWBOX does not automatically connect boxes 
  2049.  to existing lines on the screen with the proper connector characters.  If you 
  2050.  want to draw lines inside a box and have the proper connectors drawn 
  2051.  automatically, draw the box first, then use DRAWHLINE and DRAWVLINE to draw 
  2052.  the lines. 
  2053.  
  2054.  DRAWBOX uses the standard line and box drawing characters in the U.S. English 
  2055.  extended ASCII character set.  These characters are included in the English 
  2056.  language versions of standard monospaced fonts typically available under OS/2 
  2057.  (e.g. Courier, System Monospaced, or System VIO).  However, if your system is 
  2058.  configured for a different font, character set (code page), or country, or you 
  2059.  have replaced or modified the OS/2 default fonts, the box may not appear on 
  2060.  your screen as you expect. 
  2061.  
  2062.  
  2063. ΓòÉΓòÉΓòÉ 3.24. DRAWHLINE - Draw horizontal line ΓòÉΓòÉΓòÉ
  2064.  
  2065.  Purpose:    Draw a vertical line on the screen. 
  2066.  
  2067.  Format:     DRAWHLINE row column len style [BRIght] fg ON [BRIght] bg 
  2068.  
  2069.              row:  Starting row 
  2070.              column:  Starting column 
  2071.              len:  Length of line 
  2072.              style:  Line drawing style: 
  2073.               1  Single line 
  2074.               2  Double line 
  2075.              fg:  Foreground character color 
  2076.              bg:  Background character color 
  2077.  
  2078.  See also:  DRAWBOX and DRAWVLINE. 
  2079.  
  2080.  Usage: 
  2081.  
  2082.  DRAWHLINE is useful for creating attractive screen displays in batch files. 
  2083.  It detects other lines and boxes on the display, and creates the appropriate 
  2084.  connector characters when possible (not all types of lines can be connected 
  2085.  with the available characters). 
  2086.  
  2087.  For example, the following command draws a double line along the top row of 
  2088.  the display with green characters on a blue background: 
  2089.  
  2090.           drawhline 0 0 80 2 green on blue
  2091.  
  2092.  The row and column values are zero-based, so on a standard 25 line by 80 
  2093.  column display, valid rows are 0 - 24 and valid columns are 0 - 79.  DRAWHLINE 
  2094.  checks for a valid row and column, and displays a "Usage" error message if 
  2095.  either value is out of range. 
  2096.  
  2097.  See Colors and Color Names for details about colors. 
  2098.  
  2099.  DRAWHLINE uses the standard line and box drawing characters in the U.S. 
  2100.  English extended ASCII character set.  These characters are included in the 
  2101.  English language versions of standard monospaced fonts typically available 
  2102.  under OS/2 (e.g. Courier, System Monospaced, or System VIO).  However, if your 
  2103.  system is configured for a different font, character set (code page), or 
  2104.  country, or you have replaced or modified the OS/2 default fonts, the line may 
  2105.  not appear on your screen as you expect. 
  2106.  
  2107.  
  2108. ΓòÉΓòÉΓòÉ 3.25. DRAWVLINE - Draw a vertical line ΓòÉΓòÉΓòÉ
  2109.  
  2110.  Purpose:    Draw a vertical line on the screen. 
  2111.  
  2112.  Format:     DRAWVLINE row column len style [BRIght] fg ON [BRIght] bg 
  2113.  
  2114.              row:  Starting row 
  2115.              column:  Starting column 
  2116.              len:  Length of line 
  2117.              style:  Line drawing style: 
  2118.               1  Single line 
  2119.               2  Double line 
  2120.              fg:  Foreground character color 
  2121.              bg:  Background character color 
  2122.  
  2123.  See also:  DRAWBOX and DRAWHLINE. 
  2124.  
  2125.  Usage: 
  2126.  
  2127.  DRAWVLINE is useful for creating attractive screen displays in batch files. 
  2128.  It detects other lines and boxes on the display, and creates the appropriate 
  2129.  connector characters when possible (not all types of lines can be connected 
  2130.  with the available characters). 
  2131.  
  2132.  For example, to draw a double width line along the left margin of the display 
  2133.  with bright red characters on a black background: 
  2134.  
  2135.           drawvline 0 0 25 2 bright red on black
  2136.  
  2137.  The row and column values are zero-based, so on a standard 25 line by 80 
  2138.  column display, valid rows are 0 - 24 and valid columns are 0 - 79.  DRAWVLINE 
  2139.  checks for a valid row and column, and displays a "Usage" error message if 
  2140.  either value is out of range. 
  2141.  
  2142.  See Colors and Color Names for details about colors. 
  2143.  
  2144.  DRAWVLINE uses the standard line and box drawing characters in the U.S. 
  2145.  English extended ASCII character set.  These characters are included in the 
  2146.  English language versions of standard monospaced fonts typically available 
  2147.  under OS/2 (e.g. Courier, System Monospaced, or System VIO).  However, if your 
  2148.  system is configured for a different font, character set (code page), or 
  2149.  country, or you have replaced or modified the OS/2 default fonts, the line may 
  2150.  not appear on your screen as you expect. 
  2151.  
  2152.  
  2153. ΓòÉΓòÉΓòÉ 3.26. ECHO - Display a message ΓòÉΓòÉΓòÉ
  2154.  
  2155.  Purpose:    Display a message, enable or disable batch file or command-line 
  2156.              echoing, or display the echo status. 
  2157.  
  2158.  Format:     ECHO [ON | OFF | message ] 
  2159.  
  2160.              message :  Text to display. 
  2161.  
  2162.  See also:  ECHOS, SCREEN, SCRPUT, SETDOS and TEXT. 
  2163.  
  2164.  Usage: 
  2165.  
  2166.  Take Command has a separate echo capability for batch files and for the 
  2167.  command line.  The command-line ECHO state is independent of the batch file 
  2168.  ECHO state; changing ECHO in a batch file has no effect on the display at the 
  2169.  command prompt, and vice versa. 
  2170.  
  2171.  To see the current echo state, use the ECHO command with no arguments. This 
  2172.  displays either the batch file or command-line echo state, depending on where 
  2173.  the ECHO command is performed. 
  2174.  
  2175.  In a batch file, if you turn ECHO on, each line of the file is displayed 
  2176.  before it is executed.  If you turn ECHO off, each line is executed without 
  2177.  being displayed.  ECHO can also be used in a batch file to display a message 
  2178.  on the screen.  Regardless of the ECHO state, a batch file line that begins 
  2179.  with the [@] character will not be displayed.  To turn off batch file echoing, 
  2180.  without displaying the ECHO command, use this line: 
  2181.  
  2182.           @echo off
  2183.  
  2184.  ECHO commands in a batch file will send messages to the screen while the batch 
  2185.  file executes, even if ECHO is set OFF.  For example, this line will display a 
  2186.  message in a batch file: 
  2187.  
  2188.           echo Processing your print files...
  2189.  
  2190.  If you want to echo a blank line from within a batch file, enter: 
  2191.  
  2192.           echo.
  2193.  
  2194.  You cannot use the command separator character [&], or the redirection symbols 
  2195.  [| > <] in an ECHO message, unless you enclose them in quotes (see Argument 
  2196.  Quoting) or precede them with the escape character . 
  2197.  
  2198.  ECHO defaults to ON in batch files.  The current ECHO state is inherited by 
  2199.  called batch files.  You can change the default setting to ECHO OFF with the 
  2200.  SETDOS /V0 command or the BatchEcho directive in the .INI file. 
  2201.  
  2202.  If you turn the command-line ECHO on, each command will be displayed before it 
  2203.  is executed.  This will let you see the command line after expansion of all 
  2204.  aliases and variables.  The command- line ECHO is most useful when you are 
  2205.  learning how to use advanced features.  This example will turn command-line 
  2206.  echoing on: 
  2207.  
  2208.           [c:\] echo on
  2209.  
  2210.  ECHO defaults to OFF at the command line. 
  2211.  
  2212.  
  2213. ΓòÉΓòÉΓòÉ 3.27. ECHOS - Display a message with no CR/LF ΓòÉΓòÉΓòÉ
  2214.  
  2215.  Purpose:    Display a message without a trailing carriage return and line 
  2216.              feed. 
  2217.  
  2218.  Format:     ECHOS message 
  2219.  
  2220.  See also:  ECHO, SCREEN, SCRPUT, TEXT, and VSCRPUT. 
  2221.  
  2222.  Usage: 
  2223.  
  2224.  ECHOS is useful for text output when you don't want to add a carriage return / 
  2225.  linefeed pair at the end of the line.  For example, you can use ECHOS when you 
  2226.  need to redirect control sequences to your printer; this example sends the 
  2227.  sequence Esc P to the printer on LPT1: 
  2228.  
  2229.           [c:\] echos ^eP > lpt1:
  2230.  
  2231.  You cannot use the command separator character [&] or the redirection symbols 
  2232.  [| > <] in an ECHOS message, unless you enclose them in quotes (see Argument 
  2233.  Quoting) or precede them with the escape character . 
  2234.  
  2235.  ECHOS does not translate or modify the message text.  For example, carriage 
  2236.  return characters are not translated to CR/LF pairs. ECHOS sends only the 
  2237.  characters you enter (after escape character and back quote processing).  The 
  2238.  only character you cannot put into an ECHOS message is the NUL character 
  2239.  (ASCII 0). 
  2240.  
  2241.  
  2242. ΓòÉΓòÉΓòÉ 3.28. ENDLOCAL - Restore saved environment ΓòÉΓòÉΓòÉ
  2243.  
  2244.  Purpose:    Restore the saved disk drive, directory, environment, and alias 
  2245.              list. 
  2246.  
  2247.  Format:     ENDLOCAL 
  2248.  
  2249.  See also:  SETLOCAL. 
  2250.  
  2251.  Usage: 
  2252.  
  2253.  The SETLOCAL command in a batch file saves the current disk drive, default 
  2254.  directory, all environment variables, and the alias list. ENDLOCAL restores 
  2255.  everything that was saved by the previous SETLOCAL command. 
  2256.  
  2257.  SETLOCAL and ENDLOCAL can only be used in batch files, not in aliases or from 
  2258.  the command line. 
  2259.  
  2260.  
  2261. ΓòÉΓòÉΓòÉ 3.29. ESET - Edit variable or alias ΓòÉΓòÉΓòÉ
  2262.  
  2263.  Purpose:    Edit environment variables and aliases. 
  2264.  
  2265.  Format:     ESET [/A] variable name... 
  2266.  
  2267.              variable name :  The name of an environment variable or alias to 
  2268.              edit. 
  2269.  
  2270.              /A(lias) 
  2271.  
  2272.  See also:  ALIAS, UNALIAS, SET, and UNSET. 
  2273.  
  2274.  Usage: 
  2275.  
  2276.  ESET allows you to edit environment variables and aliases using line editing 
  2277.  commands (see Command-Line Editing). 
  2278.  
  2279.  For example, to edit the executable file search path: 
  2280.  
  2281.           [c:\] eset path
  2282.  
  2283.  To create and then edit an alias: 
  2284.  
  2285.           [c:\] alias d = dir /d/j/p
  2286.           [c:\] eset d
  2287.  
  2288.  ESET will search for environment variables first and then aliases. If you have 
  2289.  an environment variable and an alias with the same name, ESET will edit the 
  2290.  environment variable and ignore the alias unless you use the /A option. 
  2291.  
  2292.  Environment variable and alias names are normally limited to 80 characters, 
  2293.  and their contents to 1,023 characters.  However, if you use special 
  2294.  techniques to create a longer environment variable, ESET will edit it provided 
  2295.  the variable contains no more than 2,047 characters of text. 
  2296.  
  2297.  If you have enabled global aliases (see ALIAS), any changes made to an alias 
  2298.  with ESET will immediately affect all other copies of Take Command which are 
  2299.  using the same alias list. 
  2300.  
  2301.  Option: 
  2302.  
  2303.     /A      (Alias) Edit the named alias even if an environment variable of the 
  2304.             same name exists.  If you have an alias and an environment variable 
  2305.             with the same name, you must use this switch to be able to edit the 
  2306.             alias. 
  2307.  
  2308.  
  2309. ΓòÉΓòÉΓòÉ 3.30. EXCEPT - Exclude files from command ΓòÉΓòÉΓòÉ
  2310.  
  2311.  Purpose:    Perform a command on all available files except those specified. 
  2312.  
  2313.  Format:     EXCEPT (file ) command 
  2314.  
  2315.              file :  The file or files to exclude from the command. 
  2316.              command :  The command to execute, including all appropriate 
  2317.              arguments and switches. 
  2318.  
  2319.  See also:  ATTRIB. 
  2320.  
  2321.  File Selection: 
  2322.  
  2323.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  2324.  Date, time, or size ranges must appear immediately after the EXCEPT keyword. 
  2325.  
  2326.  Usage: 
  2327.  
  2328.  EXCEPT provides a means of executing a command on a group of files and/or 
  2329.  subdirectories, and excluding a subgroup from the operation. The command can 
  2330.  be an internal command or alias, an external command, or a batch file. 
  2331.  
  2332.  You may use wildcards to specify the files to exclude from the command.  The 
  2333.  first example erases all the files in the current directory except those 
  2334.  beginning with MEMO, and those whose extension is .WKS.  The second example 
  2335.  copies all the files and subdirectories on drive C to drive D except those in 
  2336.  C:\MSC and C:\DOS, using the COPY command: 
  2337.  
  2338.           [c:\] except (memo*.* *.wks) erase *.*
  2339.           [c:\] except (c:\msc c:\dos) copy c:\*.* d:\ /s
  2340.  
  2341.  Date, time, and size ranges can be used immediately after the word EXCEPT to 
  2342.  further qualify which files should be excluded from the command.  If the 
  2343.  command is an internal command that supports ranges, an independent range can 
  2344.  also be used in the command itself. 
  2345.  
  2346.  EXCEPT prevents operations on the specified file(s) by setting the hidden 
  2347.  attribute, performing the command, and then clearing the hidden attribute.  If 
  2348.  the command is aborted in an unusual way, you may need to use the ATTRIB 
  2349.  command to remove the hidden attribute from the file(s). 
  2350.  
  2351.  Caution:  EXCEPT will not work with programs or commands that ignore the 
  2352.  hidden attribute or which work explicitly with hidden files, including DEL /Z, 
  2353.  and the /H (process hidden files) switch available in some Take Command file 
  2354.  processing commands. 
  2355.  
  2356.  You can use command grouping to execute multiple commands with a single 
  2357.  EXCEPT.  For example, the following command copies all files in the current 
  2358.  directory whose extensions begin with .DA, except the .DAT files, to the 
  2359.  D:\SAVE directory, then changes the first two characters of the extension of 
  2360.  the copied files to .SA: 
  2361.  
  2362.           [c:\data] except (*.dat) (copy *.da* d:\save & ren *.da* *.sa*)
  2363.  
  2364.  If you use filename completion (see Filename Completion) to enter the 
  2365.  filenames inside the parentheses, type a space after the open parenthesis 
  2366.  before entering a partial filename or pressing Tab.  Otherwise, the 
  2367.  command-line editor will treat the open parenthesis as the first character of 
  2368.  the filename to be completed. 
  2369.  
  2370.  
  2371. ΓòÉΓòÉΓòÉ 3.31. EXIT - Exit Take Command ΓòÉΓòÉΓòÉ
  2372.  
  2373.  Purpose:    Return from Take Command. 
  2374.  
  2375.  Format:     EXIT [value ] 
  2376.  
  2377.              value :  The exit code to return (0 - 255). 
  2378.  
  2379.  Usage: 
  2380.  
  2381.  EXIT terminates the current copy of Take Command. 
  2382.  
  2383.  To close the session, or to return to the application that started Take 
  2384.  Command, type: 
  2385.  
  2386.           [c:\] exit
  2387.  
  2388.  If you specify a value, EXIT will return that value to the program that 
  2389.  started Take Command.  For example: 
  2390.  
  2391.           [c:\] exit 255
  2392.  
  2393.  The value is a number you can use to inform the program of some result, such 
  2394.  as the success or failure of a batch file. 
  2395.  
  2396.  
  2397. ΓòÉΓòÉΓòÉ 3.32. FFIND - Search for files or text ΓòÉΓòÉΓòÉ
  2398.  
  2399.  Purpose:    Search for files by name or contents. 
  2400.  
  2401.  Format:     FFIND [/A:[[-]rhsda] /B /C /D[list] /E /K /L /M 
  2402.              /O[[:][-]acdeginrsu] /P /S /T"xx" /V /X["xx xx ..."] file... 
  2403.  
  2404.              list :  A list of disk drive letters (without colons). 
  2405.              file :  The file, directory, or list of files or directories to 
  2406.              display. 
  2407.  
  2408.              /A(ttribute select)             /M (no footers) 
  2409.              /B(are)                         /O(rder) 
  2410.              /C(ase sensitive)               /P(ause) 
  2411.              /D(rive)                        /S(ubdirectories) 
  2412.              /E (upper case display)         /T(ext search string) 
  2413.              /K (no headers)                 /V(erbose) 
  2414.              /L(ine numbers)                 /X (hex display/search string) 
  2415.  
  2416.  File Selection: 
  2417.  
  2418.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  2419.  
  2420.  Usage: 
  2421.  
  2422.  FFIND is a flexible search command that looks for files based on their names 
  2423.  and their contents. Depending on the options you choose, FFIND can display 
  2424.  filenames, matching text, or a combination of both in a variety of formats. 
  2425.  
  2426.  If you want to search for files by name, FFIND works much like the DIR 
  2427.  command.  For example, to generate a list of all the .BTM files in the current 
  2428.  directory, you could use the command 
  2429.  
  2430.           [c:\] ffind *.btm
  2431.  
  2432.  The output from this command is a list of full pathnames, followed by the 
  2433.  number of files found. 
  2434.  
  2435.  If you want to limit the output to a list of *.BTM files which contain the 
  2436.  string color, you could use this command instead: 
  2437.  
  2438.           [c:\] ffind /t"color" *.btm
  2439.  
  2440.  The output from this version of FFIND is a list of files that contain the 
  2441.  string color along with the first line in each file that contains that string. 
  2442.  By default, FFIND uses a case-insensitive search, so the command above will 
  2443.  include files that contain COLOR, Color, color, or any other combination of 
  2444.  upper-case and lower-case letters. 
  2445.  
  2446.  You can use Take Command's extended wildcards in the search string to increase 
  2447.  the flexibility of FFIND's search.  For example, the following command will 
  2448.  find .TXT files which contain either the string June or July.  It will also 
  2449.  find Juny and Jule.  The /C option makes the search case-sensitive: 
  2450.  
  2451.           [c:\] ffind /c/t"Ju[nl][ey]" *.txt
  2452.  
  2453.  At times, you may need to search for data that cannot be represented by ASCII 
  2454.  characters.  You can use FFIND's /X option to represent the search string in 
  2455.  hexadecimal format.  With the /X option, the search must be represented by 
  2456.  pairs of hexadecimal digits separated by spaces (41 63 65 is the hex code for 
  2457.  "Ace"): 
  2458.  
  2459.           [c:\] ffind /b"41 63 65" *.txt
  2460.  
  2461.  You can use FFIND's other options to further specify the files for which you 
  2462.  are searching and to modify the way in which the output is displayed. 
  2463.  
  2464.  Options: 
  2465.  
  2466.     /A      (Attribute select) Select only those files that have the specified 
  2467.             attribute(s) set.  Preceding the attribute character with a hyphen 
  2468.             [-] will select files that do not have that attribute set.  The 
  2469.             colon [:] after /A is required.  The attributes are: 
  2470.  
  2471.                          R  Read-only 
  2472.                          H  Hidden 
  2473.                          S  System 
  2474.                          D  Subdirectory 
  2475.                          A  Archive 
  2476.  
  2477.             If no attributes are listed at all (e.g., FFIND /A: ...), FFIND 
  2478.             will select all files and subdirectories including hidden and 
  2479.             system files.  If attributes are combined, all the specified 
  2480.             attributes must match for a file to be selected. For example, 
  2481.             /A:RHS will select only those files with all three attributes set. 
  2482.  
  2483.     /B      (Bare) Display file names only and omit the text that matches the 
  2484.             search.  This option is only useful in combination with /T or /X, 
  2485.             which normally force FFIND to display file names and matching text. 
  2486.  
  2487.     /C      (Case sensitive) Perform a case-sensitive search.  This option is 
  2488.             only valid with /T, which defaults to a case-insensitive search. 
  2489.             It is not needed with a /X hexadecimal search, which is always 
  2490.             case-sensitive. 
  2491.  
  2492.     /D      (Drive)  Search all files on one or more drives.  If you use /D 
  2493.             without a list of drives, FFIND will search the drives specified in 
  2494.             the list of files.  If no drive letters are listed, FFIND will 
  2495.             search the default drive.  You can include a list of drives or a 
  2496.             range of drives to search as part of the /D option.  For example, 
  2497.             to search drives C:, D:, E:, and G:, you can use either of these 
  2498.             commands: 
  2499.  
  2500.                                 [c:\] ffind /dcdeg ...
  2501.                                 [c:\] ffind /dc-eg ...
  2502.  
  2503.     /E      Display filenames in the traditional upper case; also see SETDOS /U 
  2504.             and the UpperCase directive in TCMDOS2.INI. 
  2505.  
  2506.     /K      (No headers) Suppress the display of the header or filename for 
  2507.             each matching text line. 
  2508.  
  2509.     /L      (Line numbers) Include the line number for each text line 
  2510.             displayed. 
  2511.  
  2512.     /M      (No footers) Suppress the footer (the number of files and number of 
  2513.             matches) at the end of FFIND's display. 
  2514.  
  2515.     /O      (Order) Set the sorting order.  You may use any combination of the 
  2516.             following sorting options; if multiple options are used, the 
  2517.             listing will be sorted with the first sort option as the primary 
  2518.             key, the next as the secondary key, and so on: 
  2519.  
  2520.                          -  Reverse the sort order for the next option 
  2521.                          a  Sort in ASCII order, not numerically, when there 
  2522.                          are digits in the name 
  2523.                          d  Sort by date and time (oldest first); for HPFS 
  2524.                          drives also see /T 
  2525.                          e  Sort by extension 
  2526.                          g  Group subdirectories first, then files 
  2527.                          i  Sort by file description (ignored if /C or /O:c is 
  2528.                          used) 
  2529.                          n  Sort by filename (this is the default) 
  2530.                          r  Reverse the sort order for all options 
  2531.                          s  Sort by size 
  2532.                          u  Unsorted 
  2533.  
  2534.     /P      (Pause) Wait for a key to be pressed after each screen page before 
  2535.             continuing the display.  Your options at the prompt are explained 
  2536.             in detail under Page and File Prompts. 
  2537.  
  2538.     /S      (Subdirectories) Display matches from the current directory and all 
  2539.             of its subdirectories. 
  2540.  
  2541.     /T      (Text search) Specify the text search string.  /T must be followed 
  2542.             by a text string in double quotes (e.g., /t"color").  FFIND will 
  2543.             perform a case-insensitive search unless you also use the /C 
  2544.             option.  For a hexadecimal search and/or hexadecimal display of the 
  2545.             location where the search string is found, see /X.  You can specify 
  2546.             a search string with either /T or /X, but not both. 
  2547.  
  2548.     /V      (Verbose) Show every matching line.  FFIND's default behavior is to 
  2549.             show only the first matching line then and then go on to the next 
  2550.             file.  This option is only valid with /T or /X. 
  2551.  
  2552.     /X      (Hexadecimal display / search) Specify hexadecimal display and an 
  2553.             optional hexadecimal search string. 
  2554.  
  2555.             If /X is followed by one or more pairs of hexadecimal digits in 
  2556.             quotes (e.g., /x"44 63 65"), FFIND will search for that exact 
  2557.             sequence of characters or data bytes without regard to the meaning 
  2558.             of those bytes as text.  If those bytes are found, the offset is 
  2559.             displayed (also in hexadecimal).  A search of this type will always 
  2560.             be case-sensitive. 
  2561.  
  2562.             If /X is not followed by a hexadecimal search string it must be 
  2563.             used in conjunction with /T, and will change the output format to 
  2564.             display hexadecimal offsets rather than actual text lines when the 
  2565.             search string is found.  For example, this command uses /T to 
  2566.             display the first line in each BTM file containing the word hello: 
  2567.  
  2568.                                 [c:\] ffind /t"hello" *.btm
  2569.                                 ---- c:\test.btm:
  2570.                                 echo hello
  2571.  
  2572.                                 1 line in 1 file
  2573.  
  2574.             If you use the same command with /X, the hexadecimal offset is 
  2575.             displayed instead of the text: 
  2576.  
  2577.                                 [c:\] ffind /t"hello" /x *.btm
  2578.                                 ---- c:\test.btm:
  2579.                                 Offset: 1A
  2580.  
  2581.                                 1 line in 1 file
  2582.  
  2583.             You can specify a search string with either /T or /X, but not both. 
  2584.  
  2585.  
  2586. ΓòÉΓòÉΓòÉ 3.33. FOR - Repeat a command ΓòÉΓòÉΓòÉ
  2587.  
  2588.  Purpose:    Repeat a command for several values of a variable. 
  2589.  
  2590.  Format:     FOR [/A:[[-]rhsda] /H] %var IN ([@]set ) [DO] command ... 
  2591.  
  2592.              %var :  The variable to be used in the command ("FOR variable"). 
  2593.              set :  A set of values for the variable. 
  2594.              command :  A command or group of commands to be executed for each 
  2595.              value of the variable. 
  2596.  
  2597.              /A(ttribute select) 
  2598.              /H(ide dots) 
  2599.  
  2600.  File Selection: 
  2601.  
  2602.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  2603.  Date, time, or size ranges must appear immediately after the FOR keyword. 
  2604.  
  2605.  Usage: 
  2606.  
  2607.  FOR begins by creating a set.  It then executes a command for every member of 
  2608.  the set.  The command can be an internal command, an alias, an external 
  2609.  command, or a batch file. 
  2610.  
  2611.  Normally, the set is a list of files specified with wildcards.  For example, 
  2612.  if you use this line in a batch file: 
  2613.  
  2614.           for %x in (*.txt) do list %x
  2615.  
  2616.  then LIST will be executed once for each file in the current directory with 
  2617.  the extension .TXT.  The FOR variable %x is set equal to each of the file 
  2618.  names in turn, then the LIST command is executed for each file. (You could do 
  2619.  the same thing more easily with a simple LIST *.TXT.  We used FOR here so you 
  2620.  could get a feel for how it operates, using a simple example.) 
  2621.  
  2622.  The set can include multiple files or an include list, like this: 
  2623.  
  2624.           for %x in (d:\*.txt;*.doc;*.asc) do type %x
  2625.  
  2626.  If the set includes filenames, the file list can be further refined by using 
  2627.  date, time, and size ranges.  The range must be placed immediately after the 
  2628.  word FOR.  The range will be ignored if no wildcards are used inside the 
  2629.  parentheses.  For example, this set is made up of all of the *.TXT files that 
  2630.  were created or updated on October 4, 1994: 
  2631.  
  2632.           for /[d10-4-94,+0] %x in (*.txt) do ...
  2633.  
  2634.  If the command is an internal command that supports ranges, an independent 
  2635.  range can also be used in the command itself. 
  2636.  
  2637.  The set can also be made up of text instead of file names.  For example, to 
  2638.  display the free space on drives C:, D:, and E:, you could use: 
  2639.  
  2640.           for %drive in (c d e) do free %drive:
  2641.  
  2642.  When the set is made up of text or several separate file names (not an include 
  2643.  list), the elements must be separated by spaces, tabs, commas, or the switch 
  2644.  character (normally a slash [/]). 
  2645.  
  2646.  You can also set the FOR variable equal to each line in a file by placing an 
  2647.  [@] in front of the file name.  If you have a file called DRIVES.TXT that 
  2648.  contains a list of drives on your computer, one drive name per line (with a 
  2649.  ":" after each drive letter), you can print the free space on each drive this 
  2650.  way: 
  2651.  
  2652.           for %d in (@drives.txt) do free %d > prn
  2653.  
  2654.  Because the [@] is also a valid filename character, FOR first checks to see if 
  2655.  the file exists with the [@] in its name (i.e., a file named @DRIVES.TXT ). 
  2656.  If so, the filename is treated as a normal argument.  If it doesn't exist, FOR 
  2657.  uses the filename (without the [@]) as the file from which to retrieve text. 
  2658.  
  2659.  You can use either % or %% in front of the variable name. Either form will 
  2660.  work, whether the FOR command is typed from the command line or is part of an 
  2661.  alias or batch file (some of the traditional command processors require a 
  2662.  single % if FOR is used at the command line, but use %% if it is used in a 
  2663.  batch file).  The variable name can be up to 80 characters long.  The word DO 
  2664.  is optional. 
  2665.  
  2666.  If you use a single-character FOR variable name, that name is given priority 
  2667.  over any environment variable which starts with the same letter, in order to 
  2668.  maintain compatibility with the traditional FOR command.  For example, the 
  2669.  following command tries to add a: and b: to the end of the PATH, but will not 
  2670.  work as intended: 
  2671.  
  2672.           [c:\] for %p in (a: b:) do path %path;%p
  2673.  
  2674.  The "%p" in "%path" will be interpreted as the FOR variable %p followed by the 
  2675.  text "ath", which is not what was intended.  To get around this, use a 
  2676.  different letter or a longer name for the FOR variable, or use square brackets 
  2677.  around the variable name (see Environment). 
  2678.  
  2679.  The following example uses FOR with variable functions to delete the .BAK 
  2680.  files for which a corresponding .TXT file exists in the current directory: 
  2681.  
  2682.           [c:\docs] for %file in (*.txt) do del %@name[%file].bak
  2683.  
  2684.  You can use command grouping to execute multiple commands for each element in 
  2685.  the list.  For example, the following command copies each .WKQ file in the 
  2686.  current directory to the D:\WKSAVE directory, then changes the extension of 
  2687.  each file in the current directory to .SAV.  This should be entered on one 
  2688.  line: 
  2689.  
  2690.           [c:\text] for %file in (*.wkq) do (copy %file d:\wksave\ & ren %file
  2691.   *.sav)
  2692.  
  2693.  In a batch file you can use GOSUB to execute a subroutine for every element in 
  2694.  the set.  Within the subroutine, the FOR variable can be used just like any 
  2695.  environment variable.  This is a convenient way to execute a complex sequence 
  2696.  of commands for every element in the set without CALLing another batch file. 
  2697.  
  2698.  One unusual use of FOR is to execute a collection of batch files or other 
  2699.  commands with the same parameter.  For example, you might want to have three 
  2700.  batch files all operate on the same data file. The FOR command could look like 
  2701.  this: 
  2702.  
  2703.           [c:\] for %cmd in (filetest fileform fileprnt) do %cmd datafile
  2704.  
  2705.  This line will expand to three separate commands: 
  2706.  
  2707.           filetest datafile
  2708.           fileform datafile
  2709.           fileprnt datafile
  2710.  
  2711.  The variable that FOR uses (the %CMD in the example above) is created in the 
  2712.  environment and then erased when the FOR command is done. However, for 
  2713.  compatibility with CMD.EXE, single-character FOR variables do not overwrite 
  2714.  existing environment variables with the same name.  As a result, when using a 
  2715.  multi-character variable name you must be careful not to use the name of one 
  2716.  of your environment variables as a FOR variable.  For example, a command that 
  2717.  begins 
  2718.  
  2719.           [c:\] for %path in ...
  2720.  
  2721.  will write over your current path setting and then erase the path variable 
  2722.  completely. 
  2723.  
  2724.  FOR statements can be nested. 
  2725.  
  2726.  Options: 
  2727.  
  2728.     /A      (Attribute select) Select only those files that have the specified 
  2729.             attribute(s) set.  /A will be used only when processing wildcard 
  2730.             file names in the set.  It will be ignored for filenames without 
  2731.             wildcards or other items in the set.  Preceding the attribute 
  2732.             character with a hyphen [-] will select files that do not have that 
  2733.             attribute set.  The colon [:] after /A is required.  The attributes 
  2734.             are: 
  2735.  
  2736.                          R  Read-only 
  2737.                          H  Hidden 
  2738.                          S  System 
  2739.                          D  Subdirectory 
  2740.                          A  Archive 
  2741.  
  2742.             If no attributes are listed (e.g., FOR /A: ...), FOR will process 
  2743.             all files including hidden and system files.  If attributes are 
  2744.             combined, all the specified attributes must match for a file to be 
  2745.             included.  For example, /A:RHS will include only those files with 
  2746.             all three attributes set. 
  2747.  
  2748.             For example, to process only those files with the archive attribute 
  2749.             set: 
  2750.  
  2751.                                 for /a:a %f in (*.*) echo %f needs a backup!
  2752.  
  2753.     /H      (Hide dots) Suppress the assignment of the "." and ".." directories 
  2754.             to "var". 
  2755.  
  2756.  
  2757. ΓòÉΓòÉΓòÉ 3.34. FREE - Display total and free disk space ΓòÉΓòÉΓòÉ
  2758.  
  2759.  Purpose:    Display the total disk space, total bytes used, and total bytes 
  2760.              free on the specified (or default) drive(s). 
  2761.  
  2762.  Format:     FREE [drive: ... ] 
  2763.  
  2764.              drive :  One or more drives to include in the report. 
  2765.  
  2766.  See also:  MEMORY. 
  2767.  
  2768.  Usage: 
  2769.  
  2770.  FREE provides the same disk information as the external command CHKDSK, but 
  2771.  without the wait, since it does not check the integrity of the file and 
  2772.  directory structure of the disk. 
  2773.  
  2774.  A colon [:] is required after each drive letter. This example displays the 
  2775.  status of drives A and C: 
  2776.  
  2777.           [c:\] free a: c:
  2778.  
  2779.  
  2780. ΓòÉΓòÉΓòÉ 3.35. GLOBAL - Execute command in all subdirectories ΓòÉΓòÉΓòÉ
  2781.  
  2782.  Purpose:    Execute a command in the current directory and its subdirectories. 
  2783.  
  2784.  Format:     GLOBAL [/H /I /P /Q] command 
  2785.  
  2786.              command :  The command to execute, including arguments and 
  2787.              switches. 
  2788.  
  2789.              /H(idden directories) 
  2790.              /P(rompt) 
  2791.              /I(gnore exit codes) 
  2792.              /Q(uiet) 
  2793.  
  2794.  Usage: 
  2795.  
  2796.  GLOBAL performs the command first in the current directory and then in every 
  2797.  subdirectory under the current directory.  The command can be an internal 
  2798.  command, an alias, an external command, or a batch file. 
  2799.  
  2800.  This example copies the files in every directory on drive A to the directory 
  2801.  C:\TEMP: 
  2802.  
  2803.           [a:\] global copy *.* c:\temp
  2804.  
  2805.  If you use the /P option, GLOBAL will prompt for each subdirectory before 
  2806.  performing the command.  You can use this option if you want to perform the 
  2807.  command in most, but not all subdirectories of the current directory. 
  2808.  
  2809.  You can use command grouping to execute multiple commands in each 
  2810.  subdirectory.  For example, the following command copies each .TXT file in the 
  2811.  current directory and all of its subdirectories to drive A.  It then changes 
  2812.  the extension of each of the copied files to .SAV: 
  2813.  
  2814.           [c:\] global (copy *.txt a: & ren *.txt *.sav)
  2815.  
  2816.  Options: 
  2817.  
  2818.     /H      (Hidden directories) Forces GLOBAL to look for hidden directories. 
  2819.             If you don't use this switch, hidden directories are ignored. 
  2820.  
  2821.     /I      (Ignore exit codes) If this option is not specified, GLOBAL will 
  2822.             terminate if the command returns a non- zero exit code.  Use /I if 
  2823.             you want command to continue in additional subdirectories even if 
  2824.             it returns an error in a previous subdirectory.  Even if you use 
  2825.             /I, GLOBAL will halt execution in response to Ctrl-C or Ctrl-Break. 
  2826.  
  2827.     /P      (Prompt) Forces GLOBAL to prompt with each directory name before it 
  2828.             performs the command.  Your options at the prompt are explained in 
  2829.             detail under Page and File Prompts. 
  2830.  
  2831.     /Q      (Quiet) Do not display the directory names as each directory is 
  2832.             processed. 
  2833.  
  2834.  
  2835. ΓòÉΓòÉΓòÉ 3.36. GOSUB - Call subroutine ΓòÉΓòÉΓòÉ
  2836.  
  2837.  Purpose:    Execute a subroutine in the current batch file. 
  2838.  
  2839.  Format:     GOSUB label 
  2840.  
  2841.              label :  The batch file label at the beginning of the subroutine. 
  2842.  
  2843.  See also:  CALL, GOTO and RETURN. 
  2844.  
  2845.  Usage: 
  2846.  
  2847.  GOSUB can only be used in batch files. 
  2848.  
  2849.  Take Command allows subroutines in batch files.  A subroutine must start with 
  2850.  a label (a colon [:] followed by a one-word label name) which appears on a 
  2851.  line by itself.  Case differences are ignored when matching labels.  The 
  2852.  subroutine must end with a RETURN statement. 
  2853.  
  2854.  The subroutine is invoked with a GOSUB command from another part of the batch 
  2855.  file.  After the RETURN, processing will continue with the command following 
  2856.  the GOSUB command.  For example, the following batch file fragment calls a 
  2857.  subroutine which displays the directory and returns: 
  2858.  
  2859.           echo Calling a subroutine
  2860.           gosub subr1
  2861.           echo Returned from the subroutine
  2862.           quit
  2863.           :subr1
  2864.           dir /a/w
  2865.           return
  2866.  
  2867.  GOSUB begins its search for the label on the next line of the batch file 
  2868.  (after the GOSUB command).  If the label is not found between the current 
  2869.  position and the end of the file, GOSUB will restart the search at the 
  2870.  beginning of the file.  If the label still is not found, the batch file is 
  2871.  terminated with the error message "Label not found." 
  2872.  
  2873.  GOSUB saves the IFF state, so IFF statements inside a subroutine won't 
  2874.  interfere with IFF statements in the part of the batch file from which the 
  2875.  subroutine was called. 
  2876.  
  2877.  Subroutines can be nested. 
  2878.  
  2879.  
  2880. ΓòÉΓòÉΓòÉ 3.37. GOTO - Branch within batch file ΓòÉΓòÉΓòÉ
  2881.  
  2882.  Purpose:    Branch to a specified line inside the current batch file. 
  2883.  
  2884.  Format:     GOTO [/I] label 
  2885.  
  2886.              label :  The batch file label to branch to. 
  2887.  
  2888.              /I(FF and DO continue) 
  2889.  
  2890.  See also:  GOSUB. 
  2891.  
  2892.  Usage: 
  2893.  
  2894.  GOTO can only be used in batch files. 
  2895.  
  2896.  After a GOTO command in a batch file, the next line to be executed will be the 
  2897.  one immediately after the label.  The label must begin with a colon [:] and 
  2898.  appear on a line by itself. The colon is required on the line where the label 
  2899.  is defined, but is not required in the GOTO command itself.  Case differences 
  2900.  are ignored when matching labels. 
  2901.  
  2902.  This batch file fragment checks for the existence of the file CONFIG.SYS.  If 
  2903.  the file exists, the batch file jumps to C_EXISTS and copies all the files 
  2904.  from the current directory to the root directory on A:.  Otherwise, it prints 
  2905.  an error message and exits. 
  2906.  
  2907.           if exist config.os2 goto C_EXISTS
  2908.           echo CONFIG.SYS doesn't exist - exiting.
  2909.           quit
  2910.           :C_EXISTS
  2911.           copy *.* a:\
  2912.  
  2913.  GOTO begins its search for the label on the next line of the batch file (after 
  2914.  the GOTO command).  If the label is not found between the current position and 
  2915.  the end of the file, GOTO will restart the search at the beginning of the 
  2916.  file.  If the label still is not found, the batch file is terminated with the 
  2917.  error message "Label not found." 
  2918.  
  2919.  To avoid errors in the processing of nested statements and loops, GOTO cancels 
  2920.  all active IFF statements and DO / ENDDO loops unless you use /I.  This means 
  2921.  that a normal GOTO (without /I) may not branch to any label that is between an 
  2922.  IFF and the corresponding ENDIFF or between a DO and the corresponding ENDDO. 
  2923.  
  2924.  Options: 
  2925.  
  2926.     /I      (IFF and DO continue) Prevents GOTO from canceling IFF statements 
  2927.             and DO loops.  Use this option only if you are absolutely certain 
  2928.             that your GOTO command is branching entirely within any current IFF 
  2929.             statement and any active DO / ENDDO block.  Using /I under any 
  2930.             other conditions will cause an error later in your batch file. 
  2931.  
  2932.             You cannot branch into another IFF statement, another DO loop, or a 
  2933.             different IFF or DO nesting level, whether you use the /I option or 
  2934.             not.  If you do, you will eventually receive an "unknown command" 
  2935.             error (or execution of the UNKNOWN_CMD alias) on a subsequent 
  2936.             ENDDO, ELSE, ELSEIFF, or ENDIFF statement. 
  2937.  
  2938.  
  2939. ΓòÉΓòÉΓòÉ 3.38. HELP - Call online help ΓòÉΓòÉΓòÉ
  2940.  
  2941.  Purpose:    Display help for internal commands, and optionally for external 
  2942.              commands. 
  2943.  
  2944.  Format:     HELP [topic ] 
  2945.  
  2946.              topic :  A help topic or internal command. 
  2947.  
  2948.  Usage: 
  2949.  
  2950.  Online help is available for Take Command.  The Take Command help system uses 
  2951.  the OS/2 help facility. 
  2952.  
  2953.  If you type the command HELP by itself (or press F1 when the command line is 
  2954.  empty), the table of contents is displayed.  If you type HELP plus a topic 
  2955.  name, that topic is displayed.  For example, 
  2956.  
  2957.           help copy
  2958.  
  2959.  displays information about the COPY command and its options. 
  2960.  
  2961.  
  2962. ΓòÉΓòÉΓòÉ 3.39. HISTORY - Manage command history list ΓòÉΓòÉΓòÉ
  2963.  
  2964.  Purpose:    Display, add to, clear, or read the history list. 
  2965.  
  2966.  Format:     HISTORY [/A command /F /P /R filename ] 
  2967.  
  2968.              /A(dd) 
  2969.              /P(ause) 
  2970.              /F(ree) 
  2971.              /R(ead) 
  2972.  
  2973.  See also:  LOG. 
  2974.  
  2975.  Usage: 
  2976.  
  2977.  Take Command keeps a list of the commands you have entered on the command 
  2978.  line.  See Command History and Recall for additional details. 
  2979.  
  2980.  The HISTORY command lets you view and manipulate the command history list 
  2981.  directly.  If no parameters are entered, HISTORY will display the current 
  2982.  command history list: 
  2983.  
  2984.           [c:\] history
  2985.  
  2986.  With the options explained below, you can clear the list, add new commands to 
  2987.  the list without executing them, save the list in a file, or read a new list 
  2988.  from a file. 
  2989.  
  2990.  The number of commands saved in the history list depends on the length of each 
  2991.  command line.  The history list size can be specified at startup from 256 to 
  2992.  32767 characters (see the History directive).  The default size is 1024 
  2993.  characters. 
  2994.  
  2995.  Your history list can be stored either locally (a separate history list for 
  2996.  each copy of Take Command) or globally (all copies of Take Command share the 
  2997.  same list).  For full details see the discussion of local and global history 
  2998.  lists under Command History and Recall. 
  2999.  
  3000.  You can use the HISTORY command as an aid in writing batch files by 
  3001.  redirecting the HISTORY output to a file and then editing the file 
  3002.  appropriately.  However, it is easier to use the LOG /H command for this 
  3003.  purpose. 
  3004.  
  3005.  You can disable the history list or specify a minimum command-line length to 
  3006.  save with the HistMin directive in the .INI file. 
  3007.  
  3008.  Options: 
  3009.  
  3010.     /A      (Add) Add a command to the history list.  This performs the same 
  3011.             function as the Ctrl-K key at the command line (see Command History 
  3012.             and Recall ). 
  3013.  
  3014.     /F      (Free) Erase all entries in the command history list. 
  3015.  
  3016.     /P      (Prompt) Wait for a key after displaying each page of the list. 
  3017.             Your options at the prompt are explained in detail under Page and 
  3018.             File Prompts. 
  3019.  
  3020.     /R      (Read) Read the command history from the specified file and append 
  3021.             it to the history list currently held in memory.  Each line in the 
  3022.             file must fit within the command-line length limit). 
  3023.  
  3024.             You can save the history list by redirecting the output of HISTORY 
  3025.             to a file.  This example saves the command history to a file called 
  3026.             HISTFILE and reads it back again immediately.  If you leave out the 
  3027.             HISTORY /F command on the second line, the contents of the file 
  3028.             will be appended to the current history list instead of replacing 
  3029.             it: 
  3030.  
  3031.                                 [c:\] history > histfile
  3032.                                 [c:\] history /f
  3033.                                 [c:\] history /r histfile
  3034.  
  3035.             If you need to save your history at the end of each day's work, you 
  3036.             might use commands like this in your TCSTART or other startup 
  3037.             files: 
  3038.  
  3039.                                 if exist c:\histfile history /r c:\histfile
  3040.                                 alias shut*down `history > c:\histfile`
  3041.  
  3042.             This restores the previous history list if it exists, then defines 
  3043.             an alias which will save the history before shutting off the 
  3044.             system. 
  3045.  
  3046.             If you are creating a HISTORY /R file by hand, and need to create 
  3047.             an entry that spans multiple lines in the file, you can do so by 
  3048.             terminating each line, except the last, with an escape character. 
  3049.             However, you cannot use this method to exceed the command-line 
  3050.             length limit. 
  3051.  
  3052.  
  3053. ΓòÉΓòÉΓòÉ 3.40. IF - Test condition ΓòÉΓòÉΓòÉ
  3054.  
  3055.  Purpose:    Execute a command if a condition or set of conditions is true. 
  3056.  
  3057.  Format:     IF [NOT] condition [.AND. | .OR. | .XOR. [NOT] condition ...] 
  3058.              command 
  3059.  
  3060.              condition :  A test to determine if the command should be 
  3061.              executed. 
  3062.              command :  The command to execute if the condition is true. 
  3063.  
  3064.  See also:  IFF. 
  3065.  
  3066.  Usage: 
  3067.  
  3068.  IF is normally used only in aliases and batch files.  It is always followed by 
  3069.  one or more conditions and then a command. First, the conditions are 
  3070.  evaluated.  If they are true, the command is executed. Otherwise, the command 
  3071.  is ignored. If you add a NOT before a condition, the command is executed only 
  3072.  when the  condition is false. 
  3073.  
  3074.  You can link conditions with .AND., .OR., or .XOR., and you can nest IF 
  3075.  statements.  The conditions can test strings, numbers, the existence of a file 
  3076.  or subdirectory, the exit code returned by the preceding external command, and 
  3077.  the existence of alias names and internal commands. 
  3078.  
  3079.  The command can be an alias, an internal command, an external command, or a 
  3080.  batch file.  The entire IF statement, including all conditions and the 
  3081.  command, must fit on one line. 
  3082.  
  3083.  You can use command grouping to execute multiple commands if the condition is 
  3084.  true. For example, the following command tests if any .TXT files exist.  If 
  3085.  they do, they are copied to drive A: and their extensions are changed to .TXO: 
  3086.  
  3087.           if exist *.txt (copy *.txt a: & ren *.txt *.txo)
  3088.  
  3089.  (Note that the IFF command provides a more structured method of executing 
  3090.  multiple commands if a condition or set of conditions is true.) 
  3091.  
  3092.  Conditions 
  3093.  
  3094.  The following conditional tests are available in both the IF and IFF commands. 
  3095.  They fit into two categories:  string and numeric tests, and status tests. 
  3096.  The tests can use environment variables, internal variables and variable 
  3097.  functions, file names, literal text, and numeric values as their arguments. 
  3098.  
  3099.  Spaces are required on either side of the test condition in all cases, except 
  3100.  == which will work with or without spaces around it. 
  3101.  
  3102.  String and Numeric Tests 
  3103.  
  3104.  Six test conditions can be used to test character strings. The same conditions 
  3105.  are available for both numeric and normal text strings (see below for 
  3106.  details).  In each case you enter the test as: 
  3107.  
  3108.           string1 operator string2
  3109.  
  3110.  The operator defines the type of test (equal, greater than or equal, and so 
  3111.  on).  The operators are: 
  3112.  
  3113.         EQ or ==        string1 equal to string2 
  3114.         NE or !=        string1 not equal to string2 
  3115.         LT              string1 less than string2 
  3116.         LE              string1 less than or equal to string2 
  3117.         GE              string1 greater than or equal to string2 
  3118.         GT              string1 greater than string2 
  3119.  
  3120.  Status Tests 
  3121.  
  3122.  These conditions test the system or command processor status. You can use 
  3123.  internal variables and variable functions to test many other parts of the 
  3124.  system status. 
  3125.  
  3126.         ERRORLEVEL [operator] n
  3127.             This test retrieves the exit code of the preceding external 
  3128.             program.  By convention, programs return an exit code of 0 when 
  3129.             they are successful and a number between 1 and 255 to indicate an 
  3130.             error.  The condition can be any of the operators listed above (EQ, 
  3131.             !=, GT, etc.).  If no operator is specified, the default is GE. 
  3132.             The comparison is done numerically. 
  3133.  
  3134.             Not all programs return an explicit exit code.  For programs which 
  3135.             do not, the behavior of ERRORLEVEL is undefined. 
  3136.  
  3137.         EXIST filename
  3138.             If the file exists, the condition is true. You can use wildcards in 
  3139.             the filename, in which case the condition is true if any file 
  3140.             matching the wildcard name exists. 
  3141.  
  3142.         ISALIAS aliasname
  3143.             If the name is defined as an alias, the condition is true. 
  3144.  
  3145.         ISDIR path
  3146.             If the subdirectory exists, the condition is true. 
  3147.  
  3148.         ISINTERNAL command
  3149.             If the specified command is an active internal command, the 
  3150.             condition is true.  Commands can be activated and deactivated with 
  3151.             the SETDOS /I command. 
  3152.  
  3153.         ISLABEL label
  3154.             If the specified batch file label exists, the condition is true. 
  3155.  
  3156.         ISWINDOW "title"
  3157.             If the window with the title exists, the condition is true.  Double 
  3158.             quotes must be used around the title.  If you need to check whether 
  3159.             a window exists and you only know part of the title, use wildcards 
  3160.             to specify the window title.  For example, to test for a window 
  3161.             whose title begins with "Take Command", use a command like this: 
  3162.  
  3163.                                   if iswindow "Take Command*" ...
  3164.  
  3165.  
  3166.  Combining Tests 
  3167.  
  3168.  You can negate the result of any test with NOT, and combine tests of any type 
  3169.  with .AND., .OR., and .XOR.  Test conditions are always scanned from left to 
  3170.  right -- there is no implied order of precedence, as there is in some 
  3171.  programming languages. 
  3172.  
  3173.  When two tests are combined with .AND., the result is true if both individual 
  3174.  tests are true.  When two tests are combined with .OR., the result is true if 
  3175.  either (or both) individual tests are true.  When two tests are combined with 
  3176.  .XOR., the result is true only if one of the tests is true and the other is 
  3177.  false. 
  3178.  
  3179.  Using the IF Tests 
  3180.  
  3181.  When IF compares two character strings, it will use either a numeric 
  3182.  comparison or a string comparison.  A numeric comparison treats the strings as 
  3183.  numeric values and tests them arithmetically.  A string comparison treats the 
  3184.  strings as text. 
  3185.  
  3186.  The difference between numeric and string comparisons is best explained by 
  3187.  looking at the way two values are tested.  For example, consider comparing the 
  3188.  values 2 and 19.  Numerically, 2 is smaller, but as a string it is "larger" 
  3189.  because its first digit is larger than the first digit of 19.  So the first of 
  3190.  these condition s will be true, and the second will be false: 
  3191.  
  3192.           if 2 lt 19 ...
  3193.           if "2" lt "19" ...
  3194.  
  3195.  IF determines which kind of test to do by examining the first character of 
  3196.  each string.  If both strings begin with a numeric character (a digit, sign, 
  3197.  or decimal point), a numeric comparison is used.  If either value does not 
  3198.  begin with a numeric character, a string comparison is used.  To force a 
  3199.  string comparison when both values are or may be numeric, use double quotes 
  3200.  around the values you are testing, as shown above.  Because the double quote 
  3201.  is not a numeric character, it forces IF to do a string comparison. 
  3202.  
  3203.  Case differences are ignored in string comparisons.  If two strings begin with 
  3204.  the same text but one is shorter, the shorter string is considered to be "less 
  3205.  than" the longer one.  For example, "a" is less than "abc", and "hello_there" 
  3206.  is greater than "hello". 
  3207.  
  3208.  When you compare text strings, you should always enclose the arguments in 
  3209.  double quotes in order to avoid syntax errors which may occur if one of the 
  3210.  argument values is empty. 
  3211.  
  3212.  Numeric comparisons work with both integer and decimal values.  The values to 
  3213.  be compared must contain only numeric digits, decimal points, and an optional 
  3214.  sign ( or+-).  Decimal numbers are limited to a maximum of 16 digits to the 
  3215.  left of the decimal point and 8 digits to the right. 
  3216.  
  3217.  Internal variables and variable functions are very powerful when combined with 
  3218.  string and numeric comparisons.  They allow you to test the state of your 
  3219.  system, the characteristics of a file, date and time information, or the 
  3220.  result of a calculation.  You may want to review the variables and variable 
  3221.  functions when determining the best way to set up an IF test. 
  3222.  
  3223.  This batch file fragment tests for a string value: 
  3224.  
  3225.           input "Enter your selection : " %%cmd
  3226.           if "%cmd" == "WP" goto wordproc
  3227.           if "%cmd" NE "GRAPHICS" goto badentry
  3228.  
  3229.  This example calls GO.BTM if the first two characters in the file MYFILE are 
  3230.  "GO" (enter this example on one line): 
  3231.  
  3232.           if "%@instr[0,2,%@line[myfile,0]]"=="GO" call go.btm
  3233.  
  3234.  This batch file fragment tests for the existence of A:\JAN.DOC before copying 
  3235.  it to drive C. 
  3236.  
  3237.           if exist a:\jan.doc copy a:\jan.doc c:\
  3238.  
  3239.  This example tests the exit code of the previous program and stops all batch 
  3240.  file processing if an error occurred: 
  3241.  
  3242.           if errorlevel==0 goto success
  3243.           echo "External Error -- Batch File Ends!"
  3244.           cancel
  3245.  
  3246.  
  3247. ΓòÉΓòÉΓòÉ 3.41. IFF - IFF / THEN / ELSE conditional test ΓòÉΓòÉΓòÉ
  3248.  
  3249.  Purpose:    Perform IF / THEN / ELSE conditional execution of commands. 
  3250.  
  3251.  Format:     IFF [NOT] condition [.AND. | .OR. | .XOR. [NOT] condition ...] 
  3252.              THEN & commands 
  3253.              [ELSEIFF condition THEN & commands ] ... 
  3254.              [ELSE & commands ] 
  3255.              & ENDIFF 
  3256.  
  3257.              condition :  A test to determine if the command(s) should be 
  3258.              executed. 
  3259.              commands :  One or more commands to execute if the condition(s) is 
  3260.              true.  If you use multiple commands, they must be separated by 
  3261.              command separators or be placed on separate lines of a batch file. 
  3262.  
  3263.  See also:  IF. 
  3264.  
  3265.  Usage: 
  3266.  
  3267.  IFF is similar to the IF command, except that it can perform one set of 
  3268.  commands when a condition or set of conditions is true and different commands 
  3269.  when the conditions are false. 
  3270.  
  3271.  IFF can execute multiple commands when the conditions are true or false; IF 
  3272.  normally executes only one command.  IFF imposes no limit on the number of 
  3273.  commands and is generally a "cleaner" and more structured command than IF. 
  3274.  
  3275.  IFF is always followed by one or more conditions.  If they are true, the 
  3276.  commands that follow the word THEN are executed. Additional conditions can be 
  3277.  tested with ELSEIFF.  If none of these conditions are true, the commands that 
  3278.  follow the word ELSE are executed.  In both cases, after the selected commands 
  3279.  are executed, processing continues after the word ENDIFF. 
  3280.  
  3281.  If you add a NOT before the condition, the THEN commands are executed only 
  3282.  when the condition is false and the ELSE commands are executed only when the 
  3283.  condition is true. 
  3284.  
  3285.  The commands may be separated by command separators, or may be on separate 
  3286.  lines of a batch file.  You should include a command separator or a line break 
  3287.  after a THEN, before an ELSEIFF, and before and after an ELSE. 
  3288.  
  3289.  You can link conditions with .AND., .OR., or .XOR., and you can nest IFF 
  3290.  statements up to 15 levels deep.  The conditions can test strings or numbers, 
  3291.  the existence of a file or subdirectory, the errorlevel returned from the 
  3292.  preceding external command, and the existence of alias names and internal 
  3293.  commands. 
  3294.  
  3295.  See the IF command for a list of the possible conditions. 
  3296.  
  3297.  The commands can include any internal command, alias, external command, or 
  3298.  batch file. 
  3299.  
  3300.  The alias in this example checks to see if the argument is a subdirectory.  If 
  3301.  so, the alias deletes the subdirectory's files and removes it (enter this on 
  3302.  one line): 
  3303.  
  3304.           [c:\] alias prune `iff isdir %1 then & del /sxz %1 & else & echo Not a
  3305.   directory! & endiff`
  3306.  
  3307.  Be sure to read the cautionary notes about GOTO and IFF under the GOTO command 
  3308.  before using a GOTO inside an IFF statement. 
  3309.  
  3310.  If you want to use a pipe to send information from a previous command to a 
  3311.  command inside an IFF, use command grouping around the IFF command. For 
  3312.  example: 
  3313.  
  3314.           type myfile.txt | (iff %_batch ne 0 then & list /s & endiff)
  3315.  
  3316.  If you do not use command grouping, piping will work only to the first command 
  3317.  after the IFF. 
  3318.  
  3319.  
  3320. ΓòÉΓòÉΓòÉ 3.42. INKEY - Input a character ΓòÉΓòÉΓòÉ
  3321.  
  3322.  Purpose:    Get a single keystroke from the user and store it in an 
  3323.              environment variable. 
  3324.  
  3325.  Format:     INKEY [/C /D /K"keys" /P /Wn /X] [prompt ] %%varname 
  3326.  
  3327.              prompt :  Optional text that is displayed as a prompt. 
  3328.              varname :  The variable that will hold the user's keystroke. 
  3329.  
  3330.              /C(lear buffer) 
  3331.              /D(igits only) 
  3332.              /K(valid keystrokes) 
  3333.              /P(assword) 
  3334.              /W(ait) 
  3335.              /X (no carriage return) 
  3336.  
  3337.  See also:  INPUT. 
  3338.  
  3339.  Usage: 
  3340.  
  3341.  INKEY optionally displays a prompt.  Then it waits for a specified time or 
  3342.  indefinitely for a keystroke, and places the keystroke into an environment 
  3343.  variable.  It is normally used in batch files and aliases to get a menu choice 
  3344.  or other single-key input.  Along with the INPUT command, INKEY allows great 
  3345.  flexibility in reading input from within a batch file or alias. 
  3346.  
  3347.  If prompt text is included in an INKEY command, it is displayed while INKEY 
  3348.  waits for input. 
  3349.  
  3350.  The following batch file fragment prompts for a character and stores it in the 
  3351.  variable NUM: 
  3352.  
  3353.           inkey Enter a number from 1 to 9:  %%num
  3354.  
  3355.  INKEY reads standard input for the keystroke, so it will accept keystrokes 
  3356.  from a redirected file. You can supply a list of valid keystrokes with the /K 
  3357.  option. 
  3358.  
  3359.  Standard keystrokes with ASCII values between 1 and 255 are stored directly in 
  3360.  the environment variable.  Extended keystrokes (for example, function keys and 
  3361.  cursor keys) are stored as a string in decimal format, with a leading @ (for 
  3362.  example, the F1 key is @59). The Enter key is stored as an extended keystroke, 
  3363.  with the code @28.  See the Key Code Tables for a list of extended key codes. 
  3364.  
  3365.  If you press Ctrl-C or Ctrl-Break while INKEY is waiting for a key, execution 
  3366.  of an alias will be terminated, and execution of a batch file will be 
  3367.  suspended while you are asked whether to cancel the batch job.  In a batch 
  3368.  file you can handle Ctrl-C and Ctrl-Break yourself with the ON BREAK command. 
  3369.  
  3370.  Options: 
  3371.  
  3372.     /C      (Clear buffer) Clears the keyboard buffer before INKEY accepts 
  3373.             keystrokes.  If you use this option, INKEY will ignore any 
  3374.             keystrokes which you type, either accidentally or intentionally, 
  3375.             before INKEY is ready to accept input. 
  3376.  
  3377.     /D      (Digits only):  Prevents INKEY from accepting any keystroke except 
  3378.             a digit from 0 to 9. 
  3379.  
  3380.     /K["keys"]Specify the permissible keystrokes.  The list of valid keystrokes 
  3381.             should be enclosed in double quotes.  For alphabetic keys the 
  3382.             validity test is not case sensitive.  You can specify extended keys 
  3383.             by enclosing their names in square brackets (within the quotes), 
  3384.             for example: 
  3385.  
  3386.                                 inkey /k"ab[Alt-F10]" Enter A, B, Alt-F10 %%var
  3387.  
  3388.             See Keys and Key Names for a complete listing of the key names you 
  3389.             can use within the square brackets, and a description of the key 
  3390.             name format. 
  3391.  
  3392.             If an invalid keystroke is entered, Take Command will echo the 
  3393.             keystroke if possible, beep, move the cursor back one character, 
  3394.             and wait for another keystroke. 
  3395.  
  3396.     /P      (Password) Prevents INKEY from echoing the character. 
  3397.  
  3398.     /W      (Wait) Time-out period, in seconds, to wait for a response. If no 
  3399.             keystroke is entered by the end of the time-out period, INKEY 
  3400.             returns with the variable unchanged. You can specify /W0 to return 
  3401.             immediately if there are no keys waiting in the keyboard buffer. 
  3402.  
  3403.             For example, the following batch file fragment waits up to 10 
  3404.             seconds for a character, then tests to see if a "Y" was entered: 
  3405.  
  3406.                                 set net=N
  3407.                                 inkey /K"YN" /w10 Load network (Y/N)?  %%net
  3408.                                 iff "%net" == "Y" then
  3409.                                 rem Commands to load the network go here
  3410.                                 endiff
  3411.  
  3412.     /X      (No carriage return) Prevents INKEY from adding a carriage return 
  3413.             and line feed after the user's entry. 
  3414.  
  3415.  
  3416. ΓòÉΓòÉΓòÉ 3.43. INPUT - Input a string ΓòÉΓòÉΓòÉ
  3417.  
  3418.  Purpose:    Get a string from the keyboard and save it in an environment 
  3419.              variable. 
  3420.  
  3421.  Format:     INPUT [/C /D /E /Ln /N /P /Wn /X] [prompt ] %%varname 
  3422.  
  3423.              prompt :  Optional text that is displayed as a prompt. 
  3424.              varname :  The variable that will hold the user's input. 
  3425.  
  3426.              /C(lear buffer)                 /N(o colors) 
  3427.              /D(igits only)                  /P(assword) 
  3428.              /E(dit)                         /W(ait) 
  3429.              /L(ength)                       /X (no carriage return) 
  3430.  
  3431.  See also:  INKEY. 
  3432.  
  3433.  Usage: 
  3434.  
  3435.  INPUT optionally displays a prompt.  Then it waits for a specified time or 
  3436.  indefinitely for your entry.  It places any characters you type into an 
  3437.  environment variable.  INPUT is normally used in batch files and aliases to 
  3438.  get multi-key input.  Along with the INKEY command, INPUT allows great 
  3439.  flexibility in reading user input from within a batch file or alias. 
  3440.  
  3441.  If prompt text is included in an INPUT command, it is displayed while INPUT 
  3442.  waits for input.  Standard command-line editing keys may be used to edit the 
  3443.  input string as it is entered.  If you use the /P password option, INPUT will 
  3444.  echo asterisks instead of the keys you type. 
  3445.  
  3446.  All characters entered up to, but not including, the carriage return are 
  3447.  stored in the variable. 
  3448.  
  3449.  The following batch file fragment prompts for a string and stores it in the 
  3450.  variable FNAME: 
  3451.  
  3452.           input Enter the file name:  %%fname
  3453.  
  3454.  INPUT reads standard input, so it will accept text from a re-directed file. 
  3455.  
  3456.  If you press Ctrl-C or Ctrl-Break while INPUT is waiting for input, execution 
  3457.  of an alias will be terminated, and execution of a batch file will be 
  3458.  suspended while you are asked whether to cancel the batch job.  In a batch 
  3459.  file you can handle Ctrl-C and Ctrl-Break yourself with the ON BREAK command. 
  3460.  
  3461.  Options: 
  3462.  
  3463.     /C      (Clear buffer) Clears the keyboard buffer before INPUT accepts 
  3464.             keystrokes.  If you use this option, INPUT will ignore any 
  3465.             keystrokes which you type, either accidentally or intentionally, 
  3466.             before INPUT is ready. 
  3467.  
  3468.     /D      (Digits only): Prevents INPUT from accepting any keystrokes except 
  3469.             digits from 0 to 9. 
  3470.  
  3471.     /E      (Edit) Allows you to edit an existing value.  If there is no 
  3472.             existing value for varname, INPUT proceeds as if /E had not been 
  3473.             used, and allows you to enter a new value. 
  3474.  
  3475.     /Ln     (Length) Sets the maximum number of characters which INPUT will 
  3476.             accept to "n".  If you attempt to enter more than this number of 
  3477.             characters, INPUT will beep and prevent further input (you will 
  3478.             still be able to edit the characters typed before the limit was 
  3479.             reached). 
  3480.  
  3481.     /N      (No color) Disables the display colors set by InputColor in the 
  3482.             TCMDOS2.INI file.  With this option, INPUT will use the default 
  3483.             display colors instead. 
  3484.  
  3485.     /P      (Password) Tells INPUT to echo asterisks, instead of the characters 
  3486.             you type. 
  3487.  
  3488.     /W      (Wait) Time-out period, in seconds, to wait for a response. If no 
  3489.             keystroke is entered by the end of the time-out period, INPUT 
  3490.             returns with the variable unchanged. If you enter a key before the 
  3491.             time-out period, INPUT will wait indefinitely for the remainder of 
  3492.             the line.  You can specify /W0 to return immediately if there are 
  3493.             no keys waiting in the keyboard buffer. 
  3494.  
  3495.     /X      (No carriage return) Prevents INPUT from adding a carriage return 
  3496.             and line feed after the user's entry. 
  3497.  
  3498.  
  3499. ΓòÉΓòÉΓòÉ 3.44. KEYBD - Set keyboard toggles ΓòÉΓòÉΓòÉ
  3500.  
  3501.  Purpose:    Set the state of the keyboard toggles:  Caps Lock, Num Lock, and 
  3502.              Scroll Lock. 
  3503.  
  3504.  Format:     KEYBD [/Cn /Nn /Sn] 
  3505.  
  3506.              n :  0 to turn off the toggle, or 1 to turn on the toggle. 
  3507.              /C(aps lock) 
  3508.              /S(croll lock) 
  3509.              /N(um lock) 
  3510.  
  3511.  Usage: 
  3512.  
  3513.  Most keyboards have 3 toggle keys, the Caps Lock, Num Lock, and Scroll Lock. 
  3514.  The toggle key status is usually displayed by three lights at the top right 
  3515.  corner of the keyboard. 
  3516.  
  3517.  This command lets you turn any toggle key on or off.  It is most useful in 
  3518.  batch files and aliases if you want the keys set a particular way before 
  3519.  collecting input from the user. 
  3520.  
  3521.  For example, to turn off the Num Lock and Caps Lock keys, you can use this 
  3522.  command: 
  3523.  
  3524.           [c:\] keybd /c0 /n0
  3525.  
  3526.  If you use the KEYBD command with no switches, it will display the present 
  3527.  state of the toggle keys. 
  3528.  
  3529.  Options: 
  3530.  
  3531.     /C      (Caps lock) Turn the Caps Lock key on or off. 
  3532.  
  3533.     /N      (Num lock) Turn the Num Lock key on or off. 
  3534.  
  3535.     /S      (Scroll lock) Turn the Scroll Lock key on or off. 
  3536.  
  3537.  
  3538. ΓòÉΓòÉΓòÉ 3.45. KEYS - Enable/disable history list ΓòÉΓòÉΓòÉ
  3539.  
  3540.  Purpose:    Enable, disable, or display the history list. 
  3541.  
  3542.  Format:     KEYS [ON | OFF | LIST] 
  3543.  
  3544.  See also:  HISTORY. 
  3545.  
  3546.  Usage: 
  3547.  
  3548.  This command is provided for compatibility with KEYS command in CMD.EXE, which 
  3549.  controls the history list in OS/2. The same functions are available by setting 
  3550.  the HistMin directive in the .INI file, and by using the HISTORY command. 
  3551.  
  3552.  The history list collects the commands you type for later recall, editing, and 
  3553.  viewing.  You can view the contents of the list through the history list 
  3554.  window or by typing any of the following commands: 
  3555.  
  3556.           [c:\] history
  3557.           [c:\] history /p
  3558.           [c:\] keys list
  3559.  
  3560.  The first command displays the entire history list.  The second displays the 
  3561.  entire list and pauses at the end of each full screen. The third command 
  3562.  produces the same output as the first, except that each line is numbered. 
  3563.  
  3564.  You can disable the collection and storage of commands in the history list by 
  3565.  typing: 
  3566.  
  3567.           [c:\] keys off
  3568.  
  3569.  You can turn the history back on with the command: 
  3570.  
  3571.           [c:\] keys on
  3572.  
  3573.  If you issue the KEYS command without any parameters, Take Command will show 
  3574.  you the current status of the history list. 
  3575.  
  3576.  
  3577. ΓòÉΓòÉΓòÉ 3.46. KEYSTACK - Feed keystrokes to programs ΓòÉΓòÉΓòÉ
  3578.  
  3579.  Purpose:    Feed keystrokes to a program or command automatically. 
  3580.  
  3581.  
  3582.  Format:     KEYSTACK [/Wn] ["abc"] [keyname] [!] ... 
  3583.  
  3584.              "abc":  Literal characters to be placed in the Keystack. 
  3585.              keyname:  Name for a key to be placed in the Keystack. 
  3586.              !  Signal to clear the Keystack and the keyboard buffer. 
  3587.  
  3588.              /W(ait) 
  3589.  
  3590.  Usage: 
  3591.  
  3592.  KEYSTACK takes a series of keystrokes and feeds them to a program or command 
  3593.  as if they were typed at the keyboard.  When the program has used all of the 
  3594.  keystrokes sent by KEYSTACK, it will begin to read the keyboard for input, as 
  3595.  it normally would. 
  3596.  
  3597.  Characters entered within double quotes ("abc") will be stored "as is" in the 
  3598.  buffer.  The only items allowed outside double quotes are key names and the ! 
  3599.  and /W options. 
  3600.  
  3601.  See Keys and key names for a complete listing of key names and a description 
  3602.  of the key name format. 
  3603.  
  3604.  An exclamation mark [!] will clear all pending keystrokes in the KEYSTACK 
  3605.  buffer. 
  3606.  
  3607.  For example, to start a word processor called Word and select the second item 
  3608.  on the second menu n the menu bar, you could use the command: 
  3609.  
  3610.           [d:\doc] keystack F10 Right Down "1" ^ word
  3611.  
  3612.  This places the keystrokes for F10 (change to the menu bar), right arrow (move 
  3613.  to the File menu), down arrow (display the file menu), and "1" (open the most 
  3614.  recently used file) into the buffer, then runs Word.  When Word starts it 
  3615.  receives these keystrokes and performs the appropriate actions. 
  3616.  
  3617.  You can store a maximum of 255 characters in the KEYSTACK buffer. Each time 
  3618.  the KEYSTACK command is executed, it will clear any remaining keystrokes 
  3619.  stored by a previous KEYSTACK command. 
  3620.  
  3621.  KEYSTACK only works with OS/2 Presentation Manager applications.  Due to 
  3622.  limitations in the way OS/2 passes characters to applications, KEYSTACK cannot 
  3623.  reliably transmit keystrokes to DOS, OS/2 character-mode, or Windows programs. 
  3624.  
  3625.  KEYSTACK will send the keystrokes to the current active window.  If you want 
  3626.  to send keystrokes to another program (rather than have them function with 
  3627.  Take Command itself), you must start the program or ACTIVATE its window so it 
  3628.  can receive the keystrokes.  You can do this before or after executing the 
  3629.  KEYSTACK command.  The most reliable sequence is usually to activate the 
  3630.  program's window first, then place the keystrokes in the buffer; this helps 
  3631.  ensure that another application does not receive the keystrokes inadvertently. 
  3632.  (To do this in a batch file you must start the program with the START command 
  3633.  .  If you start it directly -- without using START -- the batch file will wait 
  3634.  for the application to complete before continuing and running the KEYSTACK 
  3635.  command, and the keystrokes will be placed in the buffer too late.) 
  3636.  
  3637.  You may need to experiment with your programs and insert delays (see the /W 
  3638.  option) to find the window activation and keystroke sequence that works for a 
  3639.  particular program. 
  3640.  
  3641.  Options: 
  3642.  
  3643.     /W      (Wait):  Delay the next keystroke in the KEYSTACK buffer by a 
  3644.             specified number of clock "ticks".  A clock tick is approximately 
  3645.             1/18 second.  The number of clock ticks to delay should be placed 
  3646.             immediately after the W, and must be between 1 and 65535 ( 65535 
  3647.             ticks is about 1 hour).  You can use the /W option as many times as 
  3648.             desired and at any point in the string of keystrokes except within 
  3649.             double quotes.  Some programs may need the delays provided by /W in 
  3650.             order to receive keystrokes properly from KEYSTACK. The only way to 
  3651.             determine what delay is needed is to experiment.  For example, to 
  3652.             start the program CADX and send it an F7, a delay of one second, 
  3653.             and a carriage return: 
  3654.  
  3655.                                 [c:\] keystack F7 /W18 Enter & cadx
  3656.  
  3657.  
  3658. ΓòÉΓòÉΓòÉ 3.47. LIST - Display file ΓòÉΓòÉΓòÉ
  3659.  
  3660.  Purpose:    Display a file, with forward and backward paging and scrolling. 
  3661.  
  3662.  Format:     LIST [/A:[[-]rhsda] /H /S /W /X] file... 
  3663.  
  3664.              file :  A file or list of files to display. 
  3665.  
  3666.              /A:(ttribute select)        /W(rap) 
  3667.              /H(igh bit off)             /X (heX display mode) 
  3668.              /S(tandard input) 
  3669.  
  3670.  See also:  TYPE. 
  3671.  
  3672.  File Selection: 
  3673.  
  3674.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  3675.  
  3676.  Usage: 
  3677.  
  3678.  LIST provides a much faster and more flexible way to view a file than TYPE, 
  3679.  without the overhead of loading and using a text editor. 
  3680.  
  3681.  LIST is most often used for displaying ASCII text files.  Most other files 
  3682.  contain non-alphabetic characters and may be unreadable, except in hex mode. 
  3683.  
  3684.  For example, to display a file called MEMO.DOC : 
  3685.  
  3686.           [c:\] list memo.doc
  3687.  
  3688.  If the file argument is a directory name, LIST will display all files in the 
  3689.  directory. 
  3690.  
  3691.  LIST uses the scroll bars or the cursor pad to scroll through the file. You 
  3692.  can select the LIST commands either with the mouse (on the toolbar and 
  3693.  scrollbars) or from the keyboard.  LIST recognizes the following keys and 
  3694.  toolbar buttons (button names are shown in parentheses): 
  3695.  
  3696.         Space               Display the next page of the file (same as PgDn). 
  3697.         Home                Display the first page of the file. 
  3698.         End                 Display the last page of the file. 
  3699.         Esc (Cont)          Exit the current file. 
  3700.         Ctrl-C (Quit)       Quit LIST. 
  3701.                            Scroll up one line. 
  3702.                            Scroll down one line. 
  3703.                            Scroll left 8 columns. 
  3704.                            Scroll right 8 columns. 
  3705.         Ctrl               Scroll left 40 columns. 
  3706.         Ctrl               Scroll right 40 columns. 
  3707.         F1                  Display online help 
  3708.         B (Back)            Go back one file to the previous file in the 
  3709.                             current group of files. 
  3710.         F (Find)            Prompt and search for a string. 
  3711.         G (Goto)            Go to a specific line, or, in hex mode, to a 
  3712.                             specific hexadecimal offset. 
  3713.         H (High)            Toggle the "strip high bit" (/H) option. 
  3714.         I (Info)            Display information on the current file (the full 
  3715.                             name, size, date, and time). 
  3716.         N (Next)            Find next matching string. 
  3717.         O (Open)            Open a different file 
  3718.         P (Print)           Print the entire file, or the selected text. 
  3719.         W (Wrap)            Toggle the "line wrap" (/W) option. 
  3720.         X (heX)             Toggle the hex-mode display (/X) option. 
  3721.  
  3722.  Text searches performed with F and N are not case sensitive.  However, if the 
  3723.  display is currently in hexadecimal mode and you press F, you will be prompted 
  3724.  for whether you want to search in hexadecimal as well.  If you answer Y, you 
  3725.  should then enter the search string as a sequence of 2-digit hexadecimal 
  3726.  numbers separated by spaces, for example 41 63 65 (these are the ASCII values 
  3727.  for the string "Ace").  Hexadecimal searches are case sensitive, and search 
  3728.  for exactly the string you enter. 
  3729.  
  3730.  You can further increase the power of LIST 's text searches by using Take 
  3731.  Commands extended wildcards in the search string.  If you want to disable 
  3732.  wildcard searches (perhaps to search for text that includes wildcard 
  3733.  characters) start the search string with a single backquote character.  A 
  3734.  trailing backquote at the end of the search string is optional. 
  3735.  
  3736.  LIST saves the search string used by F and N, so you can LIST multiple files 
  3737.  and search for the same string simply by pressing N in each file, or repeat 
  3738.  your search the next time you use LIST. 
  3739.  
  3740.  LIST normally allows long lines in the file to extend past the right edge of 
  3741.  the screen.  You can use the horizontal scrolling keys (see above) to view 
  3742.  text that extends beyond the screen width.  If you use the W command or /W 
  3743.  switch to wrap the display, each line is wrapped when it reaches the right 
  3744.  edge of the screen, and the horizontal scrolling keys are disabled. 
  3745.  
  3746.  You can use G to go to a specific line or hexadecimal offset.  When prompted 
  3747.  for a line number you can enter a negative number to go backward a specified 
  3748.  number of lines from the current position (there is no corresponding option to 
  3749.  go forward a certain number of lines).  When you use this option the number of 
  3750.  lines moved will only correspond to the line count in the LIST status bar if 
  3751.  the display is not wrapped. 
  3752.  
  3753.  If you print the file which LIST is displaying, the print format will match 
  3754.  the display format.  If you have switched to hexadecimal or wrapped mode, that 
  3755.  mode will be used for the printed output as well.  If you print in wrapped 
  3756.  mode, long lines will be wrapped at the width of the display.  If you print in 
  3757.  normal display mode without line wrap, long lines will be wrapped or truncated 
  3758.  by the printer, not by LIST.  If you have selected some text in the LIST 
  3759.  window when you select Print, the Selection checkbox in the print dialog is 
  3760.  automatically marked.  If you leave it marked, Take Command prints only the 
  3761.  selected text.  If you remove the check mark, the entire file is printed. 
  3762.  
  3763.  To copy text from the LIST window to the OS/2 clipboard, first use the mouse 
  3764.  to highlight the text, then press Ctrl-Ins, or use the Copy command on the 
  3765.  Edit menu.  You can also mark the text using mouse button 2; in this case the 
  3766.  text will be copied to the clipboard immediately when you release the mouse 
  3767.  button. 
  3768.  
  3769.  Most of the LIST keystrokes can be reassigned with key mapping directives in 
  3770.  the .INI file . 
  3771.  
  3772.  Options: 
  3773.  
  3774.     /A      (Attribute select):  Select only those files that have the 
  3775.             specified attribute(s) set.  Preceding the attribute character with 
  3776.             a hyphen [-] will select files that do not have that attribute set. 
  3777.             The colon [:] after /A is required.  The attributes are: 
  3778.  
  3779.                            R  Read-only 
  3780.                            H  Hidden 
  3781.                            S  System 
  3782.                            D  Subdirectory 
  3783.                            A  Archive 
  3784.  
  3785.             If no attributes are listed at all (e.g., LIST /A), LIST will 
  3786.             select all files and subdirectories including hidden and system 
  3787.             files.  If attributes are combined, all the specified attributes 
  3788.             must match for a file to be selected.  For example, /A:RHS will 
  3789.             select only those files with all three attributes set. 
  3790.  
  3791.     /H      (High bit off) Strip the high bit from each character before 
  3792.             displaying.  This is useful when displaying files created by some 
  3793.             word processors that turn on the high bit for formatting purposes. 
  3794.             You can toggle this option on and off from within LIST with the H 
  3795.             key. 
  3796.  
  3797.     /S      (Standard input) Read from standard input rather than a file.  This 
  3798.             allows you to redirect command output and view it with LIST.  For 
  3799.             example, to use LIST to display the output of DIR: 
  3800.  
  3801.                                 [c:\] dir | list /s
  3802.  
  3803.     /W      (Wrap) Wrap the text at the right edge of the screen. This option 
  3804.             is useful when displaying files that don't have a carriage return 
  3805.             at the end of each line.  The horizontal scrolling keys do not work 
  3806.             when the display is wrapped.  You can toggle this option on and off 
  3807.             from within LIST with the W key. 
  3808.  
  3809.     /X      (hex mode):  Display the file in hexadecimal (hex) mode. This 
  3810.             option is useful when displaying executable files and other files 
  3811.             that contain non-text characters.  Each byte of the file is shown 
  3812.             as a pair of hex characters.  The corresponding text is displayed 
  3813.             to the right of each line of hexadecimal data.  You can toggle this 
  3814.             mode on and off from within LIST with the X key. 
  3815.  
  3816.  
  3817. ΓòÉΓòÉΓòÉ 3.48. LOADBTM - Switch batch file mode ΓòÉΓòÉΓòÉ
  3818.  
  3819.  Purpose:    Switch a batch file to or from BTM mode. 
  3820.  
  3821.  Format:     LOADBTM [ON | OFF] 
  3822.  
  3823.  Usage: 
  3824.  
  3825.  Take Command recognizes two kinds of batch files: .CMD and .BTM. Batch files 
  3826.  executing in BTM mode run two to five times faster than in CMD mode.  Batch 
  3827.  files automatically start in the mode indicated by their extension. 
  3828.  
  3829.  The LOADBTM command turns BTM mode on and off.  It can be used to switch modes 
  3830.  in either a  .CMD or .BTM file. If you use LOADBTM with no argument, it will 
  3831.  display the current batch mode: LOADBTM ON or LOADBTM OFF. 
  3832.  
  3833.  LOADBTM can only be used within a batch file.  It is most often used to 
  3834.  convert a .CMD file to BTM mode without changing its extension. 
  3835.  
  3836.  Using LOADBTM to repeatedly switch modes within a batch file is not efficient. 
  3837.  In most cases the speed gained by running some parts of the file in BTM mode 
  3838.  will be more than offset by the speed lost through repeated loading of the 
  3839.  file each time BTM mode is invoked. 
  3840.  
  3841.  
  3842. ΓòÉΓòÉΓòÉ 3.49. LOG - Log commands to file ΓòÉΓòÉΓòÉ
  3843.  
  3844.  Purpose:    Save a log of commands to a disk file. 
  3845.  
  3846.  Format:     LOG [/H /W file ] [ON | OFF | text ] 
  3847.  
  3848.              file :  The name of the file to hold the log. 
  3849.              text :  An optional message that will be added to the log. 
  3850.  
  3851.              /H(istory log) 
  3852.              /W(rite to) 
  3853.  
  3854.  See also:  HISTORY. 
  3855.  
  3856.  Usage: 
  3857.  
  3858.  LOG keeps a record of all internal and external commands you use. Each entry 
  3859.  includes the current system date and time, along with the actual command after 
  3860.  any alias or variable expansion.  You can use the log file as a record of your 
  3861.  daily activities. 
  3862.  
  3863.  LOG with the /H option keeps a similar record, but it does not record the date 
  3864.  and time for each command.  In addition, it records commands before aliases 
  3865.  and variables are expanded. 
  3866.  
  3867.  By default, LOG writes to the file TCOS2LOG in the root directory of the boot 
  3868.  drive.  The default file name for LOG /H is TCOS2HLOG. 
  3869.  
  3870.  Entering LOG or LOG /H with no parameters displays the log status (ON or OFF) 
  3871.  and the name of the LOG file: 
  3872.  
  3873.           [c:\] log
  3874.           LOG (C:\TCOS2LOG) is OFF
  3875.  
  3876.  To enable or disable logging, add the word "ON" or "OFF" after the LOG 
  3877.  command: 
  3878.  
  3879.           [c:\] log on
  3880.  
  3881.  or 
  3882.  
  3883.           [c:\] log /h on
  3884.  
  3885.  Entering LOG or LOG /H with text writes a message to the log file, even if 
  3886.  logging  is set OFF.  This allows you to enter headers in the log file: 
  3887.  
  3888.           [c:\] log "Started work on the database system"
  3889.  
  3890.  The LOG file format looks like this (the exact format of the date and time 
  3891.  will vary depending on your country settings): 
  3892.  
  3893.           [mm-dd-yy  hh:mm:ss]  command
  3894.  
  3895.  The LOG /H output can be used as the basis for writing batch files. Start LOG 
  3896.  /H, then execute the commands that you want the batch file to execute.  When 
  3897.  you are finished, turn LOG /H off.  The resulting file can be turned into a 
  3898.  batch file that performs the same commands with little or no editing. 
  3899.  
  3900.  You can have both a regular log (with time and date stamping) and a history 
  3901.  log (without the time stamps) enabled simultaneously. 
  3902.  
  3903.  Options: 
  3904.  
  3905.     /H      (History log) This option turns on (or off) the history log, which 
  3906.             saves commands without the time and date stamp.  For example, to 
  3907.             turn on history logging and write to the file C:\LOG\HLOG: 
  3908.  
  3909.                                 [c:\] log /h /w c:\log\hlog
  3910.  
  3911.     /W      (Write) This switch specifies a different filename for the LOG or 
  3912.             LOG /H output.  It also automatically performs a LOG ON command. 
  3913.             For example, to turn logging on and write the log to 
  3914.             C:\LOG\LOGFILE: 
  3915.  
  3916.                                 [c:\] log /w c:\log\logfile
  3917.  
  3918.             Once you select a new file name with the LOG /W or LOG /H/W 
  3919.             command, LOG will use that file until you issue another LOG /W or 
  3920.             LOG /H/W command, or until you reboot your computer.  Turning LOG 
  3921.             or LOG /H off or on does not change the file name.  You can set the 
  3922.             default log file names when Take Command starts with the LogName 
  3923.             and HistLogName directives in the .INI file. 
  3924.  
  3925.  
  3926. ΓòÉΓòÉΓòÉ 3.50. MD - Create a subdirectory ΓòÉΓòÉΓòÉ
  3927.  
  3928.  Purpose:    Create a subdirectory. 
  3929.  
  3930.  Format:     MD [/S] pathname... 
  3931.                 or 
  3932.              MKDIR [/S] pathname... 
  3933.  
  3934.              pathname :  The name of one or more directories to create. 
  3935.  
  3936.              /S(ubdirectories) 
  3937.  
  3938.  See also:  RD. 
  3939.  
  3940.  Usage: 
  3941.  
  3942.  MD and MKDIR are synonyms.  You can use either one. 
  3943.  
  3944.  MD creates a subdirectory anywhere in the directory tree.  To create a 
  3945.  subdirectory from the root, start the pathname with a backslash [\].  For 
  3946.  example, this command creates a subdirectory called MYDIR in the root 
  3947.  directory: 
  3948.  
  3949.           [c:\] md \mydir
  3950.  
  3951.  If no path is given, the new subdirectory is created in the current directory. 
  3952.  This example creates a subdirectory called DIRTWO in the current directory: 
  3953.  
  3954.           [c:\mydir] md dirtwo
  3955.  
  3956.  To create a directory from the parent of the current directory (that is, to 
  3957.  create a sibling of the current directory), start the pathname with two 
  3958.  periods and a backslash [..\]. 
  3959.  
  3960.  Option: 
  3961.  
  3962.     /S(Subdirectories) MD creates one directory at a time unless you use the /S 
  3963.     option.  If you need to create the directory C:\ONE\TWO\THREE and none of 
  3964.     the named directories exist, you can use /S to have MD create all of the 
  3965.     necessary subdirectories for you in a single command: 
  3966.  
  3967.                 [c:\] md /s \one\two\three
  3968.  
  3969.  
  3970. ΓòÉΓòÉΓòÉ 3.51. MEMORY - Display memory status ΓòÉΓòÉΓòÉ
  3971.  
  3972.  Purpose:    Display the amount and status of Take Command and OS/2 memory. 
  3973.  
  3974.  Format:     MEMORY 
  3975.  
  3976.  Usage: 
  3977.  
  3978.  MEMORY lists the total physical and resident RAM, the largest free block in 
  3979.  RAM, the swap file size, the total and free environment and alias space, and 
  3980.  the total history space. 
  3981.  
  3982.  If the OS/2 swap file is not stored in the \OS2\SYSTEM directory of the boot 
  3983.  drive, you must use the SwapFilePath directive in TCMDOS2.INI or MEMORY will 
  3984.  not be able to display the swap file size. 
  3985.  
  3986.  
  3987. ΓòÉΓòÉΓòÉ 3.52. MOVE - Move files to another directory ΓòÉΓòÉΓòÉ
  3988.  
  3989.  Purpose:    Move files to a new directory and drive. 
  3990.  
  3991.  Format:     MOVE  [/A:[[-]rhsda] /C /D /F /H /M /N /P /Q /R /S /T /U /V] 
  3992.              source... destination 
  3993.  
  3994.              source :  A file or list of files to move. 
  3995.              destination :  The new location for the files. 
  3996.  
  3997.              /A:(ttribute select)            /P(rompt) 
  3998.              /C(hanged)                      /Q(uiet) 
  3999.              /D(irectory)                    /R(eplace) 
  4000.              /F(orce delete)                 /S(ubdirectory tree) 
  4001.              /H(idden and system)            /T(otal) 
  4002.              /M(odified files)               /U(pdate) 
  4003.              /N(othing)                      /V(erify) 
  4004.  
  4005.  See also:  COPY and RENAME. 
  4006.  
  4007.  File Selection: 
  4008.  
  4009.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  4010.  Date, time, or size ranges anywhere on the line apply to all source files. 
  4011.  
  4012.  Usage: 
  4013.  
  4014.  The MOVE command moves one or more files from one directory to another, 
  4015.  whether the directories are on the same drive or not.  It has the same effect 
  4016.  as copying the files to a new location and then deleting the originals.  Like 
  4017.  COPY and RENAME, MOVE works with single files, multiple files, and sets of 
  4018.  files specified with an include list. 
  4019.  
  4020.  The simplest MOVE command moves a single source file to a new location and, 
  4021.  optionally, gives it a new name.  These two examples both move one file from 
  4022.  drive C: to the root directory on drive A: 
  4023.  
  4024.           [c:\] move myfile.dat a:\
  4025.           [c:\] move myfile.dat a:\savefile.dat
  4026.  
  4027.  In both cases, MYFILE.DAT is removed from drive C: after it has been copied to 
  4028.  drive A:.  If a file called MYFILE.DAT in the first example, or SAVEFILE.DAT 
  4029.  in the second example, already existed on drive A:, it would be overwritten. 
  4030.  (This demonstrates the difference between MOVE and RENAME.  MOVE will move 
  4031.  files between drives and will overwrite the destination file if it exists; 
  4032.  RENAME will not.) 
  4033.  
  4034.  If you MOVE multiple files, the destination must be a directory name.  MOVE 
  4035.  will move each file into the destination directory with its original name (if 
  4036.  the target is not a directory, MOVE will display an error message and exit): 
  4037.  
  4038.           [c:\] move *.wks *.txt c:\finance\myfiles
  4039.  
  4040.  You cannot move a file to a character device like the printer, or to itself. 
  4041.  
  4042.  When you move files to another directory, if you add a backslash [\] to the 
  4043.  end of the destination name MOVE will display an error message if the name 
  4044.  does not refer to an existing directory. You can use this feature to keep MOVE 
  4045.  from treating a mistyped destination directory name as a file name, and 
  4046.  attempting to move all source files to that name.  The /D option performs the 
  4047.  same function but will also prompt to see if you want to create the 
  4048.  destination directory if it doesn't exist. 
  4049.  
  4050.  Be careful when you use MOVE with the SELECT command.  If you SELECT multiple 
  4051.  files and the target is not a directory (for example, because of a 
  4052.  misspelling), MOVE will assume it is a file name.  In this case each file will 
  4053.  be moved in turn to the target file, overwriting the previous file, and then 
  4054.  the original will be erased before the next file is moved.  At the end of the 
  4055.  command, all of the original files will have been erased and only the last 
  4056.  file will exist as the target file.  You can avoid this problem by using 
  4057.  square brackets with SELECT instead of parentheses (be sure that you don't 
  4058.  allow the command line to get too long -- watch the character count in the 
  4059.  upper left corner while you're selecting files).  MOVE will then receive one 
  4060.  list of files to move instead of a series of individual filenames, and it will 
  4061.  detect the error and halt.  You can also add a backslash [\] to the end of the 
  4062.  destination name to ensure that it is the name of a subdirectory (see above). 
  4063.  
  4064.  MOVE first attempts to rename the file(s), which is the fastest way to move 
  4065.  files between subdirectories on the same drive.  If that fails (the 
  4066.  destination is on a different drive or already exists), MOVE will copy the 
  4067.  file(s) and then delete the originals. 
  4068.  
  4069.  If MOVE must physically copy the files and delete the originals, rather than 
  4070.  renaming them (see above), then some disk space may be freed on the source 
  4071.  drive.  The free space may be the result of moving the files to another drive, 
  4072.  or of overwriting a larger destination file with a smaller source file.  MOVE 
  4073.  displays the amount of disk space recovered unless the /Q option is used (see 
  4074.  below).  It does so by comparing the amount of free disk space before and 
  4075.  after the MOVE command is executed.  However, this amount may be incorrect if 
  4076.  you are using a deletion tracking system which stores deleted files in a 
  4077.  hidden directory, or if another program performs a file operation while the 
  4078.  MOVE command is executing. 
  4079.  
  4080.  When physically copying files, MOVE preserves the hidden, system, and 
  4081.  read-only attributes of the source files, and sets the archive attribute of 
  4082.  the destination files.  However, if the files can be renamed, and no copying 
  4083.  is required, then the source file attributes are not changed. 
  4084.  
  4085.  If you MOVE files with long filenames to a volume which does not support them, 
  4086.  Take Command will display an error message. 
  4087.  
  4088.  Options: 
  4089.  
  4090.     /A      (Attribute select) Select only those files that have the specified 
  4091.             attribute(s) set.  Preceding the attribute character with a hyphen 
  4092.             [-] will select files that do not have that attribute set.  The 
  4093.             colon [:] after /A is required.  The attributes are: 
  4094.  
  4095.                          R  Read-only 
  4096.                          H  Hidden 
  4097.                          S  System 
  4098.                          D  Subdirectory 
  4099.                          A  Archive 
  4100.  
  4101.             If no attributes are listed at all (e.g., MOVE /A: ...), MOVE will 
  4102.             select all files and subdirectories including hidden and system 
  4103.             files.  If attributes are combined, all the specified attributes 
  4104.             must match for a file to be selected. For example, /A:RHS will 
  4105.             select only those files with all three attributes set. 
  4106.  
  4107.     /C      (Changed files) Move files only if the destination file exists and 
  4108.             is older than the source (see also /U).  This option is useful for 
  4109.             updating the files in one directory from those in another without 
  4110.             moving any newly-created files. 
  4111.  
  4112.     /D      (Directory) Requires that the destination be a directory.  If the 
  4113.             destination does not exist, MOVE will prompt to see if you want to 
  4114.             create it. If the destination exists as a file, MOVE will fail with 
  4115.             an "Access denied" error.  Use this option to avoid having MOVE 
  4116.             accidentally interpret your destination name as a file name when 
  4117.             it's really a mistyped directory name. 
  4118.  
  4119.     /F      (Force delete) This option forces deletion of the source file 
  4120.             without saving it to the DELDIR directory (if DELDIR is not in use, 
  4121.             /F has no effect). 
  4122.  
  4123.     /H      (Hidden) Move all files, including hidden and system files. 
  4124.  
  4125.     /M      (Modified files) Move only files that have the archive bit set. The 
  4126.             archive bit will remain set after the MOVE; to clear it use ATTRIB. 
  4127.  
  4128.     /N      (Nothing) Do everything except actually move the file(s). This 
  4129.             option is most useful for testing what a complex MOVE command will 
  4130.             do. 
  4131.  
  4132.     /P      (Prompt) Prompt the user to confirm each move.  Your options at the 
  4133.             prompt are explained in detail under Page and File Prompts. 
  4134.  
  4135.     /Q      (Quiet) Don't display filenames, the total number of files moved, 
  4136.             or the amount of disk space recovered, if any.  This option is most 
  4137.             often used in batch files. See also /T. 
  4138.  
  4139.     /R      (Replace) Prompt for a Y or N response before overwriting an 
  4140.             existing destination file. 
  4141.  
  4142.     /S      (Subdirectories) Move an entire subdirectory tree to another 
  4143.             location.  MOVE will attempt to create the destination directories 
  4144.             if they don't exist, and will remove empty subdirectories after the 
  4145.             move. When /D is used with /S, you will be prompted if the first 
  4146.             destination directory does not exist, but subdirectories below that 
  4147.             will be created automatically by MOVE.  If you attempt to use /S to 
  4148.             move a subdirectory tree into part of itself, MOVE will display an 
  4149.             error message and halt. 
  4150.  
  4151.     /T      (Total) Don't display filenames as they are moved, but display the 
  4152.             total number of files deleted and the amount of free disk space 
  4153.             recovered, if any. 
  4154.  
  4155.     /U      (Update) Move each source file only if it is newer than a matching 
  4156.             destination file or if a matching destination file does not exist 
  4157.             (also see /C).  This option is useful for moving new or changed 
  4158.             files from one directory to another. 
  4159.  
  4160.     /V      (Verify) Verify each disk write.  This is the same as executing the 
  4161.             VERIFY ON command, but is only active during the MOVE.  /V does not 
  4162.             read back the file and compare its contents with what was written; 
  4163.             it only verifies that the data written to disk is physically 
  4164.             readable. 
  4165.  
  4166.  
  4167. ΓòÉΓòÉΓòÉ 3.53. MSGBOX - Display a message box prompt ΓòÉΓòÉΓòÉ
  4168.  
  4169.  Purpose:    Display a message box and return the user's response. 
  4170.  
  4171.  Format:     MSGBOX OK | OKCANCEL | YESNO | YESNOCANCEL ["title"] prompt 
  4172.  
  4173.              title : Text for the title of the message box. 
  4174.              prompt : Text that will appear inside the message box. 
  4175.  
  4176.  Usage: 
  4177.  
  4178.  MSGBOX can display one of 4 kinds of message boxes and wait for the user's 
  4179.  response.  You can use title and prompt to display any text you wish.  If no 
  4180.  title is specified, the program name ("Take Command for OS/2") is used as the 
  4181.  title.  Take Command automatically sizes and locates the box on the screen. 
  4182.  
  4183.  The message box may have 1, 2, or 3 response buttons.  The command MSGBOX OK 
  4184.  creates a single-button box; the user must simply acknowledge the prompt text. 
  4185.  
  4186.  The OKCANCEL and YESNO forms have 2 buttons each.  The YESNOCANCEL form has 3 
  4187.  buttons.  The button the user chooses is returned in the Take Command variable 
  4188.  %_?.  Be sure to save the return value in another variable or test it 
  4189.  immediately; the value of %_? changes with every internal command. 
  4190.  
  4191.  The following list shows the value returned for each possible selection: 
  4192.  
  4193.           Yes:    10
  4194.           No:     11
  4195.           OK:     10
  4196.           Cancel: 12
  4197.  
  4198.  If there is an error in the MSGBOX command itself, %_? will be set to 1 for a 
  4199.  syntax error or 2 for any other error. 
  4200.  
  4201.  
  4202. ΓòÉΓòÉΓòÉ 3.54. ON - Trap errors in batch files ΓòÉΓòÉΓòÉ
  4203.  
  4204.  Purpose:    Execute a command in a batch file when a specific condition 
  4205.              occurs. 
  4206.  
  4207.  Format:     ON BREAK [command ] 
  4208.                 or 
  4209.              ON ERROR [command ] 
  4210.                 or 
  4211.              ON ERRORMSG [command ] 
  4212.  
  4213.  Usage: 
  4214.  
  4215.  ON can only by used in batch files. 
  4216.  
  4217.  ON sets a "watchdog" that remains in effect for the duration of the current 
  4218.  batch file.  Whenever a BREAK or ERROR condition occurs after ON has been 
  4219.  executed, the command is automatically executed. 
  4220.  
  4221.  ON BREAK will execute its command if the user presses Ctrl- C or Ctrl-Break. 
  4222.  
  4223.  ON ERROR will execute its command after any command processor or operating 
  4224.  system error (including critical errors). That is, ON ERROR will detect errors 
  4225.  such as a disk write error, and Take Command errors such as a COPY command 
  4226.  that fails to copy any files, or the use of an unacceptable command option. 
  4227.  The normal error message is not displayed when ON ERROR is used. 
  4228.  
  4229.  ON ERRORMSG is the same as ON ERROR, but displays the usual error message 
  4230.  before executing the command.  The additional information about ON ERROR below 
  4231.  also applies to ON ERRORMSG. 
  4232.  
  4233.  ON BREAK and ON ERROR are independent of each other.  You can use either one, 
  4234.  or both, in any batch file. 
  4235.  
  4236.  Each time ON BREAK or ON ERROR is used, it defines a new command to be 
  4237.  executed for a break or error, and any old command is discarded.  If you use 
  4238.  ON BREAK or ON ERROR with no following command, that type of error handling is 
  4239.  disabled. Error handling is also automatically disabled when the batch file 
  4240.  exits. 
  4241.  
  4242.  ON BREAK and ON ERROR only affect the current batch file.  If you CALL another 
  4243.  batch file, the first batch file's error handling is suspended, and the CALLed 
  4244.  file must define its own error handling. When control returns to the first 
  4245.  batch file, its error handling is reactivated. 
  4246.  
  4247.  The command can be any command that can be used on a batch file line by 
  4248.  itself.  Frequently, it is a GOTO or GOSUB command.  For example, the 
  4249.  following fragment traps any user attempt to end the batch file by pressing 
  4250.  Ctrl-C or Ctrl-Break.  It scolds the user for trying to end the batch file and 
  4251.  then continues displaying the numbers from 1 to 1000: 
  4252.  
  4253.           on break gosub gotabreak
  4254.           do i = 1 to 1000
  4255.           echo %i
  4256.           enddo
  4257.           quit
  4258.           :gotabreak
  4259.           echo Hey!  Stop that!!
  4260.           return
  4261.  
  4262.  You can use a command group as the command if you want to execute multiple 
  4263.  commands, for example: 
  4264.  
  4265.           on break (echo
  4266.           Oops, got a break! & quit)
  4267.  
  4268.  ON BREAK and ON ERROR always assume that you want to continue executing the 
  4269.  batch file.  After the command is executed, control automatically returns to 
  4270.  the next command in the batch file (the command after the one that was 
  4271.  interrupted by the break or error).  The only way to avoid continuing the 
  4272.  batch file after a break or error is for the command to transfer control to 
  4273.  another point with GOTO, end the batch file with QUIT or CANCEL, or start 
  4274.  another batch file (without CALLing it). 
  4275.  
  4276.  When handling an error condition with ON ERROR, you may find it useful to use 
  4277.  internal variables, particularly %_? and %_SYSERR, to help determine the cause 
  4278.  of the error. 
  4279.  
  4280.  Caution:  If a break or error occurs while the command specified in ON BREAK 
  4281.  or ON ERROR is executing, the command will be restarted. This means you must 
  4282.  use caution to avoid or handle any possible errors in the commands invoked by 
  4283.  ON ERROR, since such errors can cause an infinite loop. 
  4284.  
  4285.  
  4286. ΓòÉΓòÉΓòÉ 3.55. PATH - Set the executable search path ΓòÉΓòÉΓòÉ
  4287.  
  4288.  Purpose:    Display or alter the list of directories that Take Command will 
  4289.              search for executable files, batch files, and files with 
  4290.              executable extensions that are not in the current directory. 
  4291.  
  4292.  Format:     PATH [directory [;directory...]] 
  4293.  
  4294.              directory :  The full name of a directory to include in the path 
  4295.              setting. 
  4296.  
  4297.  See also:  ESET and SET. 
  4298.  
  4299.  Usage: 
  4300.  
  4301.  When Take Command is asked to execute an external command (a .COM, .EXE, .BTM, 
  4302.  .BAT, or .CMD file, or an executable extension), it first looks for the file 
  4303.  in the current directory, and if it hasn't found an executable file, then 
  4304.  searches each of the directories specified in the PATH setting. 
  4305.  
  4306.           [c:\] path c:\;c:\dos;c:\util
  4307.  
  4308.  The list of directories to search is stored as an environment string, and can 
  4309.  also be set or viewed with SET, and edited with ESET. 
  4310.  
  4311.  Directory names in the path must be separated by semicolons [;].  Each 
  4312.  directory name is shifted to upper case to maintain compatibility with 
  4313.  programs which can only recognize upper case directory names in the path.  If 
  4314.  you modify your path with the SET or ESET command, you may include directory 
  4315.  names in lower case.  These may cause trouble with some programs, which assume 
  4316.  that all path entries have been shifted to upper case. 
  4317.  
  4318.  If you enter PATH with no parameters, the current path is displayed: 
  4319.  
  4320.           [c:\] path
  4321.           PATH=C:\;C:\DOS;C:\UTIL
  4322.  
  4323.  Entering PATH and a semicolon clears the search path so that only the current 
  4324.  directory is searched for executable files (this is the default at system 
  4325.  startup). 
  4326.  
  4327.  Some applications also use the PATH to search for their data files. 
  4328.  
  4329.  If you include an explicit file extension on a command name (for example, 
  4330.  WP.EXE ), the search will find files with that name and extension in the 
  4331.  current directory and every directory in the path. It will not locate other 
  4332.  executable files with the same base name. 
  4333.  
  4334.  If you have an entry in the path which consists of a single period [.], the 
  4335.  current directory will not be searched first, but instead will be searched 
  4336.  when Take Command reaches the "." in the path. This allows you to delay the 
  4337.  search of the current directory for executable files and files with executable 
  4338.  extensions.  In rare cases, this feature may not be compatible with 
  4339.  applications which use the path to find their files; if you experience a 
  4340.  problem, you will have to remove the "." from the path while using any such 
  4341.  application. 
  4342.  
  4343.  To create a path longer than the command-line length limit, use PATH 
  4344.  repeatedly to append additional directories to the path: 
  4345.  
  4346.           path [first list of directories]
  4347.           path %path;[second list of directories]
  4348.           ...
  4349.  
  4350.  You cannot use this method to extend the path beyond 2042 characters (the 
  4351.  internal buffer limit, with room for "PATH ").  It is usually more efficient 
  4352.  to use aliases to load application programs than to create a long PATH.  See 
  4353.  ALIAS for details. 
  4354.  
  4355.  If you specify an invalid directory in the path, it will be skipped and the 
  4356.  search will continue with the next directory in the path. 
  4357.  
  4358.  
  4359. ΓòÉΓòÉΓòÉ 3.56. PAUSE - Suspend batch file execution ΓòÉΓòÉΓòÉ
  4360.  
  4361.  Purpose:    Suspend batch file or alias execution. 
  4362.  
  4363.  Format:     PAUSE [text ] 
  4364.  
  4365.              text :  The message to be displayed as a user prompt. 
  4366.  
  4367.  Usage: 
  4368.  
  4369.  A PAUSE command will suspend execution of a batch file or alias, giving you 
  4370.  the opportunity to change disks, turn on the printer, etc. 
  4371.  
  4372.  PAUSE waits for any key to be pressed and then continues execution. You can 
  4373.  specify the text that PAUSE displays while it waits for a keystroke, or let 
  4374.  Take Command use the default message: 
  4375.  
  4376.           Press any key when ready...
  4377.  
  4378.  For example, the following batch file fragment prompts the user before erasing 
  4379.  files: 
  4380.  
  4381.           pause Press Ctrl-C to abort, any other key to erase all .LST files
  4382.           erase *.lst
  4383.  
  4384.  If you press Ctrl-C or Ctrl-Break while PAUSE is waiting for a key, execution 
  4385.  of an alias will be terminated, and execution of a batch file will be 
  4386.  suspended while you are asked whether to cancel the batch job.  In a batch 
  4387.  file you can handle Ctrl-C and Ctrl-Break yourself with the ON BREAK command. 
  4388.  
  4389.  
  4390. ΓòÉΓòÉΓòÉ 3.57. POPD - Restore previous directory ΓòÉΓòÉΓòÉ
  4391.  
  4392.  Purpose:    Return to the disk drive and directory at the top of the directory 
  4393.              stack. 
  4394.  
  4395.  Format:     POPD [*] 
  4396.  
  4397.  See also:  DIRS and PUSHD. 
  4398.  
  4399.  Usage: 
  4400.  
  4401.  Each time you use the PUSHD command, it saves the current disk drive and 
  4402.  directory on the internal directory stack.  POPD restores the last drive and 
  4403.  directory that was saved with PUSHD and removes that entry from the stack. 
  4404.  You can use these commands together to change directories, perform some work, 
  4405.  and return to the starting drive and directory. 
  4406.  
  4407.  Directory changes made with POPD are recorded for display in the directory 
  4408.  history window. 
  4409.  
  4410.  This example saves and changes the current disk drive and directory with 
  4411.  PUSHD, and then restores it.  The current directory is shown in the prompt: 
  4412.  
  4413.           [c:\] pushd d:\database\test
  4414.           [d:\database\test] popd
  4415.           [c:\]
  4416.  
  4417.  You can use the DIRS command to see the complete list of saved drives and 
  4418.  directories (the directory stack). 
  4419.  
  4420.  The POPD command followed by an asterisk [*] clears the directory stack 
  4421.  without changing the current drive and directory.  If the directory on the top 
  4422.  of the stack is not on the current drive, POPD will switch to the drive and 
  4423.  directory on the top of the stack without changing the default directory on 
  4424.  the current drive. 
  4425.  
  4426.  
  4427. ΓòÉΓòÉΓòÉ 3.58. PROMPT - Change command-line prompt ΓòÉΓòÉΓòÉ
  4428.  
  4429.  Purpose:    Change the command-line prompt. 
  4430.  
  4431.  Format:     PROMPT [text ] 
  4432.  
  4433.              text :  Text to be used as the new command-line prompt. 
  4434.  
  4435.  Usage: 
  4436.  
  4437.  You can change and customize the command-line prompt at any time. The prompt 
  4438.  can include normal text, and system information such as the current drive and 
  4439.  directory, the time and date, and the amount of memory available. You can 
  4440.  create an informal "Hello, Bob!" prompt or an official-looking prompt full of 
  4441.  impressive information. The prompt text can contain special commands in the 
  4442.  form $?, where ? is one of the characters listed below: 
  4443.  
  4444.         b     The vertical bar character [|]. 
  4445.         c     The open parenthesis [(]. 
  4446.         d     Current date, in the format:  Fri  1-05-96 (the month, day, and 
  4447.               year are formatted according to your current country settings). 
  4448.         D     Current date, in the format:  Fri  Jan 6, 1996. 
  4449.         e     The ASCII ESC character (decimal 27). 
  4450.         f     The close parenthesis [)]. 
  4451.         g     The > character. 
  4452.         h     Backspace over the previous character. 
  4453.         i     Ignored, included for compatibility with CMD.EXE. 
  4454.         l     The < character. 
  4455.         m     Time in hours and minutes using 24-hour format:  16:07 
  4456.         M     Time in hours and minutes using the default country format and 
  4457.               retaining "a" or "p", e.g. 4:07p. 
  4458.         n     Current drive letter. 
  4459.         p     Current directory on drive d: (including drive letter), in lower 
  4460.               case. 
  4461.         P     Current directory on drive d: (including drive letter), in upper 
  4462.               case. 
  4463.         q     The = character. 
  4464.         r     The numeric exit code of the last external command. 
  4465.         s     The space character. 
  4466.         t     Current 24-hour time, in the format hh:mm:ss. 
  4467.         T     Current 12-hour time, in the format hh:mm:ss[a|p]. 
  4468.         v     Operating system version number, in the format 3.10. 
  4469.         xd:   Current directory on drive d:, in lower case (uses the actual 
  4470.               case of the directory name as stored on the disk for HPFS 
  4471.               drives). 
  4472.         Xd:   Current directory on drive d:, in upper case. 
  4473.         z     Current shell nesting level; the primary command processor is 
  4474.               shell 0. 
  4475.         $     The $ character. 
  4476.         _     CR/LF (go to beginning of a new line). 
  4477.  
  4478.  For example, to set the prompt to the current date and time, with a ">" at the 
  4479.  end: 
  4480.  
  4481.           [c:\] prompt $d $t $g
  4482.           Fri  Jan 5, 1996 10:29:19 >
  4483.  
  4484.  To set the prompt to the current date and time, followed by the current drive 
  4485.  and directory in upper case on the next line, surrounded by square brackets: 
  4486.  
  4487.           [c:\] prompt $d $t$_[$P]
  4488.           Fri  Jan 5, 1996 10:29:19
  4489.           [C:\]
  4490.  
  4491.  The Take Command prompt can be set in TCSTART, or in any batch file that runs 
  4492.  when Take Command starts.  The Take Command default prompt is [$n] (drive name 
  4493.  in square brackets) on floppy drives, and [$p] (current drive and directory in 
  4494.  square brackets) on all other drives. 
  4495.  
  4496.  If you enter PROMPT with no arguments, the prompt will be reset to its default 
  4497.  value.  The PROMPT command sets the environment variable PROMPT, so to view 
  4498.  the current prompt setting use the command: 
  4499.  
  4500.           [c:\] set prompt
  4501.  
  4502.  (If the prompt is not set at all, the PROMPT environment variable will not be 
  4503.  used, in which case the SET command above will give a "Not in environment" 
  4504.  error.) 
  4505.  
  4506.  Along with literal text, special characters, and ANSI sequences, you can 
  4507.  include the text of any environment variable, internal variable, or variable 
  4508.  function in a prompt.  For example, if you want to include the size of the 
  4509.  largest free memory block in the command prompt, plus the current drive and 
  4510.  directory, you could use this command: 
  4511.  
  4512.           [c:\] prompt (%%@dosmem[K]K) [$p]
  4513.           (2488K) [c:\data]
  4514.  
  4515.  Notice that the @DOSMEM function is shown with two leading percent signs [%]. 
  4516.  If you used only one percent sign, the @DOSMEM function would be expanded once 
  4517.  when the PROMPT command was executed, instead of every time the prompt is 
  4518.  displayed.  As a result, the amount of memory would never change from the 
  4519.  value it had when you entered the PROMPT command. You can also use back quotes 
  4520.  to delay expanding the variable function until the prompt is displayed: 
  4521.  
  4522.           [c:\] prompt `(%@dosmem[K]K) [$p]`
  4523.  
  4524.  
  4525. ΓòÉΓòÉΓòÉ 3.59. PUSHD - Save current directory ΓòÉΓòÉΓòÉ
  4526.  
  4527.  Purpose:    Save the current disk drive and directory, optionally changing to 
  4528.              a new drive and directory. 
  4529.  
  4530.  Format:     PUSHD [pathname ] 
  4531.  
  4532.              pathname :  The name of the new default drive and directory. 
  4533.  
  4534.  See also:  DIRS, POPD and the CDPATH environment variable. 
  4535.  
  4536.  Usage: 
  4537.  
  4538.  PUSHD saves the current drive and directory on a "last in, first out" 
  4539.  directory stack.  The POPD command returns to the last drive and directory 
  4540.  that was saved by PUSHD.  You can use these commands together to change 
  4541.  directories, perform some work, and return to the starting drive and 
  4542.  directory.  The DIRS command displays the contents of the directory stack. 
  4543.  
  4544.  To save the current drive and directory, without changing directories, use the 
  4545.  PUSHD command by itself, with no pathname. 
  4546.  
  4547.  If a pathname is specified as part of the PUSHD command, the current drive and 
  4548.  directory are saved and PUSHD changes to the specified drive and directory. 
  4549.  If the pathname includes a drive letter, PUSHD changes to the specified 
  4550.  directory on the new drive without changing the current directory on the 
  4551.  original drive. 
  4552.  
  4553.  This example saves the current directory and changes to C:\WORDP\MEMOS, then 
  4554.  returns to the original directory: 
  4555.  
  4556.           [c:\] pushd \wordp\memos
  4557.           [c:\wordp\memos] popd
  4558.           [c:\]
  4559.  
  4560.  Directory changes made with PUSHD are recorded for display in the directory 
  4561.  history window. 
  4562.  
  4563.  The directory stack can hold up to 255 characters, or about 10 to 20 entries 
  4564.  (depending on the length of the names).  If you exceed this limit, the oldest 
  4565.  entry is removed before adding a new entry. 
  4566.  
  4567.  If PUSHD can't change directly to the specified directory, it will look for 
  4568.  the CDPATH variable; see CDPATH for details. 
  4569.  
  4570.  
  4571. ΓòÉΓòÉΓòÉ 3.60. QUERYBOX - Popup dialog for input ΓòÉΓòÉΓòÉ
  4572.  
  4573.  Purpose:    Display a query in a dialog box, and return the string value 
  4574.              entered. 
  4575.  
  4576.  Format:     QUERYBOX /E /Ln ["title"] prompt %%var 
  4577.  
  4578.              title: Text for the title bar of the message box. 
  4579.              prompt: Text that will appear inside the message box. 
  4580.              %%var : Variable name where the input will be saved. 
  4581.  
  4582.              /E (dit existing value) 
  4583.              /L (maximum length) 
  4584.  
  4585.  Usage: 
  4586.  
  4587.  QUERYBOX displays a dialog box with a prompt, an optional title, and a string 
  4588.  input field.  Then it waits for your entry, and places any characters you type 
  4589.  into an environment variable.  QUERYBOX is normally used in batch files and 
  4590.  aliases to get string input. 
  4591.  
  4592.  QUERYBOX is similar to INPUT, except that it appears as a popup dialog box. 
  4593.  
  4594.  This example prompts for a string and store it in the variable NAME: 
  4595.  
  4596.           querybox "File Name" Enter a name:  %%var
  4597.  
  4598.  Options: 
  4599.  
  4600.     /E      (Edit existing value) Allows you to edit an existing value.  If 
  4601.             there is no existing value for the specified variable, QUERYBOX 
  4602.             allows you to enter a new value. 
  4603.  
  4604.     /L      (Length) Sets the maximum number of characters which QUERYBOX will 
  4605.             accept to "n". 
  4606.  
  4607.  
  4608. ΓòÉΓòÉΓòÉ 3.61. QUIT - Exit batch file ΓòÉΓòÉΓòÉ
  4609.  
  4610.  Purpose:    Terminate the current batch file. 
  4611.  
  4612.  Format:     QUIT [value ] 
  4613.  
  4614.              value :  The exit code from 0 to 255 to return to Take Command or 
  4615.              to the previous batch file. 
  4616.  
  4617.  See also:  CANCEL. 
  4618.  
  4619.  Usage: 
  4620.  
  4621.  QUIT provides a simple way to exit a batch file before reaching the end of the 
  4622.  file.  If you QUIT a batch file called from another batch file, you will be 
  4623.  returned to the previous file at the line following the original CALL. 
  4624.  
  4625.  QUIT only ends the current batch file.  To end all batch file processing, use 
  4626.  the CANCEL command. 
  4627.  
  4628.  If you specify a value, QUIT will set the ERRORLEVEL or exit code (see the IF 
  4629.  command, and the %? variable) to that value. 
  4630.  
  4631.  You can also use QUIT to terminate an alias.  If you QUIT an alias while 
  4632.  inside a batch file, QUIT will end both the alias and the batch file and 
  4633.  return you to the command prompt or to the calling batch file. 
  4634.  
  4635.  
  4636. ΓòÉΓòÉΓòÉ 3.62. RD - Remove subdirectory ΓòÉΓòÉΓòÉ
  4637.  
  4638.  Purpose:    Remove one or more subdirectories. 
  4639.  
  4640.  Format:     RD pathname... 
  4641.                 or 
  4642.              RMDIR pathname... 
  4643.  
  4644.              pathname :  The name of one or more subdirectories to remove. 
  4645.  
  4646.  See also:  MD. 
  4647.  
  4648.  File Selection: 
  4649.  
  4650.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  4651.  
  4652.  Usage: 
  4653.  
  4654.  RD and RMDIR are synonyms.  You can use either one. 
  4655.  
  4656.  RD removes directories from the directory tree.  For example, to remove the 
  4657.  subdirectory MEMOS from the subdirectory WP, you can use this command: 
  4658.  
  4659.           [c:\] rd \wp\memos
  4660.  
  4661.  Before using RD, you must delete all files and subdirectories (and their 
  4662.  files) in the pathname you want to remove.  Remember to remove hidden and 
  4663.  read-only files as well as normal files (you can use DEL /Z to delete hidden 
  4664.  and read-only files). 
  4665.  
  4666.  You cannot use wildcards in the pathname. 
  4667.  
  4668.  You cannot remove the root directory, the current directory (.), any directory 
  4669.  above the current directory in the directory tree, or any directory in use by 
  4670.  another process. 
  4671.  
  4672.  
  4673. ΓòÉΓòÉΓòÉ 3.63. REBOOT - Reboot or shutdown the computer ΓòÉΓòÉΓòÉ
  4674.  
  4675.  Purpose:    Do a system reboot. 
  4676.  
  4677.  Format:     REBOOT [/S /V] 
  4678.  
  4679.              /S(hutdown) 
  4680.              /V(erify) 
  4681.  
  4682.  Usage: 
  4683.  
  4684.  REBOOT will restart your computer.  It normally performs a warm reboot, which 
  4685.  is comparable to pressing Ctrl-Alt-Delete.  The following example prompts you 
  4686.  to verify the reboot, then does a warm boot: 
  4687.  
  4688.           [c:\] reboot /v
  4689.  
  4690.  REBOOT defaults to performing a warm boot, with no prompting. 
  4691.  
  4692.  REBOOT flushes the disk buffers, resets the drives, and waits one second 
  4693.  before rebooting, to allow disk caching programs to finish writing any cached 
  4694.  data.  Take Command issues the proper commands to shut down OS/2 before 
  4695.  rebooting. 
  4696.  
  4697.  Options: 
  4698.  
  4699.     /S      (Shutdown) Shut down the system, but do not reboot.  This option is 
  4700.             equivalent to clicking the "Shutdown" choice on the OS/2 Workplace 
  4701.             Shell popup menu. 
  4702.  
  4703.     /V      (Verify) Prompt for confirmation (Y or N) before rebooting or 
  4704.             taking the action specified by other REBOOT options. 
  4705.  
  4706.  
  4707. ΓòÉΓòÉΓòÉ 3.64. REM - Add comment to batch file ΓòÉΓòÉΓòÉ
  4708.  
  4709.  Purpose:    Put a comment in a batch file. 
  4710.  
  4711.  Format:     REM [comment ] 
  4712.  
  4713.              comment :  The text to include in the batch file. 
  4714.  
  4715.  Usage: 
  4716.  
  4717.  The REM command lets you place a remark or comment in a batch file. Batch file 
  4718.  comments are useful for documenting the purpose of a batch file and the 
  4719.  procedures you have used. 
  4720.  
  4721.  REM must be followed by a space or tab character and then your comment. 
  4722.  Comment lines can be up to 1023 characters long.  Take Command will normally 
  4723.  ignore everything on the line after the REM command, including quote 
  4724.  characters, redirection symbols, and other commands (see below for the 
  4725.  exception to this rule). 
  4726.  
  4727.  If ECHO is ON, the comment is displayed.  Otherwise, it is ignored. If ECHO is 
  4728.  ON and you don't want to display the line, preface the REM command with an at 
  4729.  sign [@]. 
  4730.  
  4731.  You can use REM to create a zero-byte file if you use a redirection symbol 
  4732.  immediately after the REM command.  For example, to create the zero-byte file 
  4733.  C:\FOO: 
  4734.  
  4735.           [c:\] rem>foo
  4736.  
  4737.  (This capability is included for compatibility with traditional command 
  4738.  processors.  A simpler method for creating a zero-byte file with Take Command 
  4739.  is to enter >filename as a command, with no actual command before the [>] 
  4740.  redirection character.) 
  4741.  
  4742.  
  4743. ΓòÉΓòÉΓòÉ 3.65. REN - Rename files ΓòÉΓòÉΓòÉ
  4744.  
  4745.  Purpose:    Rename files or subdirectories. 
  4746.  
  4747.  Format:     REN [/A:[[-]rhsda] /N /P /Q /S /T] old_name... new_name 
  4748.                 or 
  4749.              RENAME [/A:[[-]rhsda] /N /P /Q /S /T] old_name... new_name 
  4750.  
  4751.              old_name :  Original name of the file(s) or subdirectory. 
  4752.              new_name :  New name to use, or new path on the same drive. 
  4753.  
  4754.              /A:(ttribute select)            /Q(uiet) 
  4755.              /N(othing)                      /S(ubdirectory) 
  4756.              /P(rompt)                       /T(otal) 
  4757.  
  4758.  See also:  COPY and MOVE. 
  4759.  
  4760.  File Selection: 
  4761.  
  4762.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  4763.  
  4764.  Usage: 
  4765.  
  4766.  REN and RENAME are synonyms.  You may use either one. 
  4767.  
  4768.  REN lets you change the name of a file or a subdirectory, or move one or more 
  4769.  files to a new subdirectory on the same drive.  (If you want to move files to 
  4770.  a different drive, use MOVE.) 
  4771.  
  4772.  In its simplest form, you simply give REN the old_name of an existing file or 
  4773.  subdirectory and then a new_name.  The new_name must not already exist -- you 
  4774.  can't give two files the same name (unless they are in different directories). 
  4775.  The first example renames the file MEMO.TXT to MEM.TXT. The second example 
  4776.  changes the name of the \WORD directory to \WP: 
  4777.  
  4778.           [c:\] rename memo.txt mem.txt
  4779.           [c:\] rename \word \wp
  4780.  
  4781.  You can also use REN to rename a group of files that you specify with 
  4782.  wildcards, as multiple files, or in an include list.  When you do, the 
  4783.  new_name must use one or more wildcards to show what part of each filename to 
  4784.  change.  Both of the next two examples change the extensions of multiple files 
  4785.  to .SAV: 
  4786.  
  4787.           [c:\] ren config.nt autoexec.nt tcstart.btm *.sav
  4788.           [c:\] ren *.txt *.sav
  4789.  
  4790.  REN can move files to a different subdirectory on the same drive. When it is 
  4791.  used for this purpose, REN requires one or more filenames for the old_name and 
  4792.  a directory name for the new_name: 
  4793.  
  4794.           [c:\] ren memo.txt \wp\memos\
  4795.           [c:\] ren oct.dat nov.dat \data\save\
  4796.  
  4797.  The final backslash in the last two examples is optional.  If you use it, you 
  4798.  force REN to recognize the last argument as the name of a directory, not a 
  4799.  file.  The advantage of this approach is that if you accidentally mistype the 
  4800.  directory name, REN will report an error instead of renaming your files in a 
  4801.  way that you didn't intend. 
  4802.  
  4803.  Finally, REN can move files to a new directory and change their name at the 
  4804.  same time if you specify both a path and file name for new_name .  In this 
  4805.  example, the files are renamed with an extension of .SAV as they are moved to 
  4806.  a new directory: 
  4807.  
  4808.           [c:\] ren *.dat \data\save\*.sav
  4809.  
  4810.  When new_name refers to a file or files (rather than a directory), the file(s) 
  4811.  must not already exist.  Also, you cannot rename a subdirectory to a new 
  4812.  location on the directory tree. 
  4813.  
  4814.  REN does not change a file's attributes.  The new_name file(s) will have the 
  4815.  same attributes as old_name. 
  4816.  
  4817.  Options: 
  4818.  
  4819.     /A      (Attribute select) Select only those files that have the specified 
  4820.             attribute(s) set.  Preceding the attribute character with a hyphen 
  4821.             [-] will select files that do not have that attribute set.  The 
  4822.             colon [:] after /A is required.  The attributes are: 
  4823.  
  4824.                          R  Read-only 
  4825.                          H  Hidden 
  4826.                          S  System 
  4827.                          D  Subdirectory 
  4828.                          A  Archive 
  4829.  
  4830.             If no attributes are listed at all (e.g., REN /A: ...), REN will 
  4831.             select all files and subdirectories including hidden and system 
  4832.             files.  If attributes are combined, all the specified attributes 
  4833.             must match for a file to be selected. For example, /A:RHS will 
  4834.             select only those files with all three attributes set. 
  4835.  
  4836.     /N      (Nothing) Do everything except actually rename the file(s). This 
  4837.             option is useful for testing what a REN command will actually do. 
  4838.  
  4839.     /P      (Prompt) Prompt the user to confirm each rename operation. Your 
  4840.             options at the prompt are explained in detail under Page and File 
  4841.             Prompts. 
  4842.  
  4843.     /Q      (Quiet) Don't display filenames  or the number of files renamed. 
  4844.             This option is most often used in batch files.  See also /T. 
  4845.  
  4846.     /S      (Subdirectory) Normally, you can rename a subdirectory only if you 
  4847.             do not use any wildcards in the new_name.  This prevents 
  4848.             subdirectories from being renamed inadvertently when a group of 
  4849.             files is being renamed with wildcards.  /S will let you rename a 
  4850.             subdirectory even when you use wildcards. 
  4851.  
  4852.     /T      (Total) Don't display filenames as they are renamed, but report the 
  4853.             number of files renamed.  See also /Q. 
  4854.  
  4855.  
  4856. ΓòÉΓòÉΓòÉ 3.66. RETURN - Return from GOSUB ΓòÉΓòÉΓòÉ
  4857.  
  4858.  Purpose:    Return from a GOSUB (subroutine) in a batch file. 
  4859.  
  4860.  Format:     RETURN 
  4861.  
  4862.  See also:  GOSUB. 
  4863.  
  4864.  Usage: 
  4865.  
  4866.  Take Command allows subroutines in batch files. 
  4867.  
  4868.  A subroutine begins with a label (a colon followed by a word) and ends with a 
  4869.  RETURN command. 
  4870.  
  4871.  The subroutine is invoked with a GOSUB command from another part of the batch 
  4872.  file.  When a RETURN command is encountered the subroutine terminates, and 
  4873.  execution of the batch file continues on the line following the original 
  4874.  GOSUB. 
  4875.  
  4876.  The following batch file fragment calls a subroutine which displays the files 
  4877.  in the current directory: 
  4878.  
  4879.           echo Calling a subroutine
  4880.           gosub subr1
  4881.           echo Returned from the subroutine
  4882.           quit
  4883.           :subr1
  4884.           dir /a/w
  4885.           return
  4886.  
  4887.  
  4888. ΓòÉΓòÉΓòÉ 3.67. SCREEN - Position cursor ΓòÉΓòÉΓòÉ
  4889.  
  4890.  Purpose:    Position the cursor on the screen and optionally display a 
  4891.              message. 
  4892.  
  4893.  Format:     SCREEN row column [text ] 
  4894.  
  4895.              row :  The new row location for the cursor. 
  4896.              column :  The new column location for the cursor. 
  4897.              text :  Optional text to display at the new cursor location. 
  4898.  
  4899.  See also:  ECHO, SCRPUT, TEXT, and VSCRPUT. 
  4900.  
  4901.  Usage: 
  4902.  
  4903.  SCREEN allows you to create attractive screen displays in batch files. You use 
  4904.  it to specify where a message will appear on the screen.  You can use SCREEN 
  4905.  to create menu displays, logos, etc. The following batch file fragment 
  4906.  displays a menu: 
  4907.  
  4908.           @echo off
  4909.           cls
  4910.           screen 3 10 Select a number from 1 to 4:
  4911.           screen 6 20  1 - Word Processing
  4912.           ...
  4913.  
  4914.  SCREEN does not change the screen colors.  To display text in specific colors, 
  4915.  use SCRPUT or VSCRPUT.  SCREEN always leaves the cursor at the end of the 
  4916.  displayed text. 
  4917.  
  4918.  The row and column values are zero-based, so on a standard 25 line by 80 
  4919.  column display, valid rows are 0 - 24 and valid columns are 0 - 79.  You can 
  4920.  also specify the row and column as offsets from the current cursor position. 
  4921.  Begin the value with a plus sign [+] to move the cursor down the specified 
  4922.  number of rows or to the right the specified number of columns, or with a 
  4923.  minus sign [-] to move the cursor up or to the left. This example prints a 
  4924.  string 3 lines above the current position, in absolute column 10: 
  4925.  
  4926.           screen -3 10 Hello, World!
  4927.  
  4928.  SCREEN checks for a valid row and column, and displays a "Usage" error message 
  4929.  if either value is out of range. 
  4930.  
  4931.  
  4932. ΓòÉΓòÉΓòÉ 3.68. SCRPUT - Display text in color ΓòÉΓòÉΓòÉ
  4933.  
  4934.  Purpose:    Position text on the screen and display it in color. 
  4935.  
  4936.  Format:     SCRPUT row col [BRIght] fg ON [BRIght] bg text 
  4937.  
  4938.              row:  Starting row 
  4939.              col:  Starting column 
  4940.              fg:  Foreground character color 
  4941.              bg:  Background character color 
  4942.              text:  The text to display 
  4943.  
  4944.  See also:  CLS, ECHO, SCREEN, TEXT, and VSCRPUT. 
  4945.  
  4946.  Usage: 
  4947.  
  4948.  SCRPUT allows you to create attractive screen displays in batch files. You use 
  4949.  it to specify where a message will appear on the screen and what colors will 
  4950.  be used to display the message text. You can use SCRPUT to create menu 
  4951.  displays, logos, etc. 
  4952.  
  4953.  SCRPUT works like SCREEN, but allows you to specify the display colors.  It 
  4954.  always leaves the cursor in its current position. 
  4955.  
  4956.  The row and column are zero-based, so on a standard 25 line by 80 column 
  4957.  display, valid rows are 0 - 24 and valid columns are 0 - 79.  You can also 
  4958.  specify the row and column as offsets from the current cursor position.  Begin 
  4959.  the value with a plus sign [+] to move down the specified number of rows or to 
  4960.  the right the specified number of columns, or with a minus sign [-] to move up 
  4961.  or to the left. 
  4962.  
  4963.  The following batch file fragment displays part of a menu, in color: 
  4964.  
  4965.           cls white on blue
  4966.           scrput 6 20 bri red on blu 1 - Word Processing
  4967.           scrput 7 20 bri yel on blu 2 - Spreadsheet
  4968.  
  4969.  
  4970. ΓòÉΓòÉΓòÉ 3.69. SELECT - Select files for a command ΓòÉΓòÉΓòÉ
  4971.  
  4972.  Purpose:    Interactively select files for a command. 
  4973.  
  4974.  Format:     SELECT [/A[:][-][rhsda] /D /E /H /I"text" /O[:][-] adeginrsu /Z] 
  4975.              [command ] ... (files...)... 
  4976.  
  4977.              command :  The command to execute with the selected files. 
  4978.              files :  The files from which to select.  File names may be 
  4979.              enclosed in either parentheses or square brackets.  The difference 
  4980.              is explained below. 
  4981.  
  4982.              /A(ttribute select)             /I (match descriptions) 
  4983.              /D(isable color coding)         /O(rder) 
  4984.              /E (use upper case)             /Z (use FAT format) 
  4985.              /H(ide dots) 
  4986.  
  4987.  File Selection: 
  4988.  
  4989.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  4990.  Date, time, or size ranges must appear immediately after the SELECT keyword. 
  4991.  
  4992.  Usage: 
  4993.  
  4994.  SELECT allows you to select files for internal and external commands by using 
  4995.  a full-screen "point and shoot" display.  You can have SELECT execute a 
  4996.  command once for each file you select, or have it create a list of files for a 
  4997.  command to work with.  The command can be an internal command, an alias, an 
  4998.  external command, or a batch file. 
  4999.  
  5000.  If you use parentheses around the files, SELECT executes the command once for 
  5001.  each file you have selected.  During each execution, one of the selected files 
  5002.  is passed to the command as an argument.  If you use square brackets around 
  5003.  files, the SELECTed files are combined into a single list, separated by 
  5004.  spaces. The command is then executed once with the entire list presented as 
  5005.  its command-line arguments. 
  5006.  
  5007.  You can scroll through the SELECT list with the scrollbars or with the 
  5008.  keyboard.  SELECT uses the cursor up, cursor down, cursor left, cursor right, 
  5009.  PgUp, and PgDn keys to scroll through the files matching the argument(s). 
  5010.  Click on a line to select or deselect it, or use the + key or space bar to 
  5011.  select a file, and the - key to deselect a file.  The "Toggle" button or  key 
  5012.  will reverse all of the current marks (excluding subdirectories), and the 
  5013.  "Clear" button or / key will unmark everything. After marking the files, click 
  5014.  on "Go" or press Enter to execute the command.  You can select a single file 
  5015.  by moving the scroll bar to the filename and selecting "Go" or pressing Enter. 
  5016.  To skip the files listed in the current display and go on to the next file 
  5017.  specification inside the parentheses or brackets (if any), press the Esc key 
  5018.  or click on the Quit button.  To cancel the current SELECT command entirely, 
  5019.  press Ctrl-C or Ctrl-Break. 
  5020.  
  5021.  On drives which support long file names, SELECT will use the standard long 
  5022.  name display format with the filename at the right-hand side of the display. 
  5023.  File descriptions are not displayed in this format.  To switch to the more 
  5024.  traditional "FAT" (short name) format, and display the file descriptions, use 
  5025.  the /Z switch. 
  5026.  
  5027.  In the simplest form of SELECT, you merely specify the command and then the 
  5028.  list of files from which you will make your selection(s). For example: 
  5029.  
  5030.           [c:\] select copy (*.com *.exe) a:\
  5031.  
  5032.  will let you select from among the .COM and .EXE files on the current drive. 
  5033.  It will then invoke the COPY command to copy each file you select to drive A:. 
  5034.  You will be able to select first from a list of all .COM files in the current 
  5035.  directory, and then from a list of all .EXE files. 
  5036.  
  5037.  If you want to select from a list of all the .COM and .EXE files mixed 
  5038.  together, create an include list inside the parentheses by inserting a 
  5039.  semicolon: 
  5040.  
  5041.           [c:\] select copy (*.com;*.exe) a:\
  5042.  
  5043.  Finally, if you want the SELECT command to send a single list of files to 
  5044.  COPY, instead of invoking COPY once for each file you select, put the file 
  5045.  names in square brackets instead of parentheses: 
  5046.  
  5047.           [c:\] select copy [*.com;*.exe] a:\
  5048.  
  5049.  If you use brackets, you have to be sure that the resulting command (the word 
  5050.  COPY, the list of files, and the destination drive in this example) is no more 
  5051.  than 1,023 characters long.  The current line length is displayed by SELECT 
  5052.  while you are marking files to help you to conform to this limit. 
  5053.  
  5054.  The parentheses or brackets enclosing the file name(s) can appear anywhere 
  5055.  within the command; SELECT assumes that the first set of parentheses or 
  5056.  brackets it finds is the one containing the list of files from which you wish 
  5057.  to make your selection. 
  5058.  
  5059.  The list of files from which you wish to select can be further refined by 
  5060.  using date, time, and size ranges. The range must be placed immediately after 
  5061.  the word SELECT.  If the command is an internal command that supports ranges, 
  5062.  an independent range can also be used in the command itself. 
  5063.  
  5064.  If you don't specify a command, the selected filename(s) will become the 
  5065.  command.  For example, this command defines an alias called UTILS that selects 
  5066.  from the executable files in the directory C:\UTIL, and then executes them in 
  5067.  the order marked: 
  5068.  
  5069.           [c:\] alias utils select (c:\util\*.com;*.exe;*.btm;*.bat)
  5070.  
  5071.  If you want to use filename completion to enter the filenames inside the 
  5072.  parentheses, type a space after the opening parenthesis. Otherwise the 
  5073.  command-line editor will treat the open parenthesis as the first character of 
  5074.  the filename. 
  5075.  
  5076.  When displaying descriptions, SELECT adds a right arrow at the end of the line 
  5077.  if the description is too long to fit on the screen.  This symbol will alert 
  5078.  you to the existence of additional description text. 
  5079.  
  5080.  With the /I option, you can select files based on their descriptions.  SELECT 
  5081.  will display files if their description matches the text after the /I switch. 
  5082.  The search is not case sensitive.  You can use wildcards and extended wild 
  5083.  cards as part of the text. 
  5084.  
  5085.  When sorting file names and extensions for the SELECT display, Take Command 
  5086.  normally assumes that sequences of digits should be sorted numerically (for 
  5087.  example, the file DRAW2 would come before DRAW03 because 2 is numerically 
  5088.  smaller than 03), rather than strictly alphabetically (where DRAW2 would come 
  5089.  second because "2" comes after "0").  You can defeat this behavior and force a 
  5090.  strict alphabetic sort with the /O:a option. 
  5091.  
  5092.  Options: 
  5093.  
  5094.     /A      (Attribute select) Select only those files that have the specified 
  5095.             attribute(s) set.  Preceding the attribute character with a hyphen 
  5096.             [-] will select files that do not have that attribute set.  The 
  5097.             colon [:] after /A is optional.  The attributes are: 
  5098.  
  5099.                          R  Read-only 
  5100.                          H  Hidden 
  5101.                          S  System 
  5102.                          D  Subdirectory 
  5103.                          A  Archive 
  5104.  
  5105.             If no attributes are listed at all (e.g., SELECT /A ...), SELECT 
  5106.             will display all files and subdirectories including hidden and 
  5107.             system files. If attributes are combined, all the specified 
  5108.             attributes must match for a file to be included in the listing. 
  5109.             For example, /A:RHS will display only those files with all three 
  5110.             attributes set. 
  5111.  
  5112.     /D      (Disable color coding)  Temporarily turn off directory color coding 
  5113.             within SELECT. 
  5114.  
  5115.     /E      (use upper case)  Display filenames in the traditional upper case 
  5116.             format; also see SETDOS /U and the UpperCase  directive in the .INI 
  5117.             file. 
  5118.  
  5119.     /H      (Hide dots)  Suppress the display of the "." and ".." directories 
  5120.  
  5121.     /I      (match descriptions)  Display filenames by matching text in their 
  5122.             descriptions.  The text can include wild cards and extended 
  5123.             wildcards.  The search text must be enclosed in quotation marks. 
  5124.  
  5125.     /O      (Order)  Set the sort order for the files.  The order can be any 
  5126.             combination of the following options: 
  5127.  
  5128.               -  Reverse the sort order for the next option 
  5129.               a  Sort in ASCII order, not numerically, when there are digits in 
  5130.             the name 
  5131.               d  Sort by date and time (oldest first); for HPFS drives also see 
  5132.             /T 
  5133.               e  Sort by extension 
  5134.               g  Group subdirectories first, then files 
  5135.               i  Sort by file description 
  5136.               n  Sort by filename (this is the default) 
  5137.               r  Reverse the sort order for all options 
  5138.               s  Sort by size 
  5139.               u  Unsorted 
  5140.  
  5141.     /Z      Display HPFS filenames in FAT format.  Long names will be truncated 
  5142.             to 12 characters.  If the name is longer than 12 characters, it 
  5143.             will be followed by a right arrow to show that one or more 
  5144.             characters have been truncated. 
  5145.  
  5146.  
  5147. ΓòÉΓòÉΓòÉ 3.70. SET - Set environment variables ΓòÉΓòÉΓòÉ
  5148.  
  5149.  Purpose:    Display, create, modify, or delete environment variables. 
  5150.  
  5151.  Format:     SET [/P /R filename...] [name [=][value ]] 
  5152.  
  5153.              filename :  The name of a file containing variable definitions. 
  5154.              name :  The name of the environment variable to define or modify. 
  5155.              value :  The new value for the variable. 
  5156.  
  5157.              /P(ause)                /R(ead from file) 
  5158.  
  5159.  See also:  ESET and UNSET. 
  5160.  
  5161.  Usage: 
  5162.  
  5163.  Every program and command inherits an environment, which is a list of variable 
  5164.  names, each of which is followed by an equal sign and some text.  Many 
  5165.  programs use entries in the environment to modify their own actions. 
  5166.  
  5167.  If you simply type the SET command with no options or arguments, it will 
  5168.  display all the names and values currently stored in the environment. 
  5169.  Typically, you will see an entry called PATH, an entry called CMDLINE, and 
  5170.  whatever other environment variables you and your programs have established: 
  5171.  
  5172.           [c:\] set
  5173.           PATH=C:\;C:\OS2;C:\OS2\SYSTEM;C:\UTIL
  5174.           CMDLINE=C:\Take Command\TCSTART.CMD
  5175.  
  5176.  To add a variable to the environment, type SET, a space, the variable name, an 
  5177.  equal sign, and the text: 
  5178.  
  5179.           [c:\] set mine=c:\finance\myfiles
  5180.  
  5181.  The variable name is converted to upper case by Take Command.  The text after 
  5182.  the equal sign will be left just as you entered it.  If the variable already 
  5183.  exists, its value will be replaced with the new text that you entered. 
  5184.  
  5185.  Normally you should not put a space on either side of the equal sign. A space 
  5186.  before the equal sign will become part of the name ; a space after the equal 
  5187.  sign will become part of the value. 
  5188.  
  5189.  If you use SET to create a variable with the same name as one of the Take 
  5190.  Command internal variables, you will disable the internal variable.  If you 
  5191.  later execute a batch file or alias that depends on that internal variable, it 
  5192.  may not operate correctly. 
  5193.  
  5194.  To display the contents of a single variable, type SET plus the variable name: 
  5195.  
  5196.           [c:\] set mine
  5197.  
  5198.  You can edit environment variables with the ESET command.  To remove variables 
  5199.  from the environment, use UNSET, or type SET plus a variable name and an equal 
  5200.  sign: 
  5201.  
  5202.           [c:\] set mine=
  5203.  
  5204.  The variable name is limited to a maximum of 80 characters. The name and value 
  5205.  together cannot be longer than 1,023 characters. 
  5206.  
  5207.  In Take Command the size of the environment is set automatically, and 
  5208.  increased as necessary as you add variables. 
  5209.  
  5210.  Options: 
  5211.  
  5212.     /P      (Pause) Wait for a key to be pressed after each screen page before 
  5213.             continuing the display.  Your options at the prompt are explained 
  5214.             in detail under Page and File Prompts. 
  5215.  
  5216.     /R      (Read) Read environment variables from a file.  This is much faster 
  5217.             than loading variables from a batch file with multiple SET 
  5218.             commands.  Each entry in the file must fit within the 1,023-byte 
  5219.             command-line length limit for Take Command:  The file is in the 
  5220.             same format as the SET display, so SET /R can accept as input a 
  5221.             file generated by redirecting SET output.  For example, the 
  5222.             following commands will save the environment variables to a file, 
  5223.             and then reload them from that file: 
  5224.  
  5225.                                 set > varlist
  5226.                                 set /r varlist
  5227.  
  5228.             You can load variables from multiple files by listing the filenames 
  5229.             individually after the /R. You can add comments to a variable file 
  5230.             by starting the comment line with a colon [:]. 
  5231.  
  5232.             If you are creating a SET /R file by hand, and need to create an 
  5233.             entry that spans multiple lines in the file, you can do so by 
  5234.             terminating each line, except the last, with an escape character. 
  5235.             However, you cannot use this method to exceed the command-line 
  5236.             length limit. 
  5237.  
  5238.  
  5239. ΓòÉΓòÉΓòÉ 3.71. SETDOS - Set the Take Command configuration ΓòÉΓòÉΓòÉ
  5240.  
  5241.  Purpose:    Display or set the Take Command configuration. 
  5242.  
  5243.  Format:     SETDOS [/A /C? /D /E? /Fn.n /I+|- command /M? /N? /P? /R? S?:? /U? 
  5244.              /V? /X[+|-]n /Y] 
  5245.  
  5246.                           /A(NSI)
  5247.              /N(o clobber) 
  5248.              /C(ompound)                   /P(arameter character) 
  5249.              /D(escriptions)               /S(hape of cursor) 
  5250.              /E(scape character)           /U(pper case) 
  5251.              /F(@EVAL format)              /V(erbose) 
  5252.              /I(nternal commands)          /X (expansion) 
  5253.              /M(ode for editing)           /Y (single step) 
  5254.  
  5255.  Usage: 
  5256.  
  5257.  SETDOS allows you to customize certain aspects of Take Command to suit your 
  5258.  personal tastes or the configuration of your system.  Each of these options is 
  5259.  described below. 
  5260.  
  5261.  You can display the value of all SETDOS options by entering the SETDOS command 
  5262.  with no parameters. 
  5263.  
  5264.  Most of the SETDOS options can be initialized when Take Command executes the 
  5265.  configuration directives in the .INI file, and can also be changed from the 
  5266.  configuration notebook. The name of the corresponding directive is listed with 
  5267.  each option below; if none is listed, that option cannot be set from the .INI 
  5268.  file. You can also define the SETDOS options in your TCSTART or other startup 
  5269.  file (see Automatic Batch Files), in aliases, or at the command line. 
  5270.  
  5271.  Options: 
  5272.  
  5273.     /A      (ANSI) The ANSI option determines whether Take Command will handle 
  5274.             ANSI strings displayed on the screen (for example, in the prompt or 
  5275.             with the ECHO command).  /A0 disables ANSI support; /A1 enables it. 
  5276.             See the ANSI Reference for more details on ANSI strings, and a 
  5277.             reference list of ANSI sequences supported by Take Command for 
  5278.             OS/2. You can test whether ANSI support is enabled with the _ANSI 
  5279.             internal variable.  Also see the ANSIdirective. 
  5280.  
  5281.     /C      (Compound character) The COMPOUND option sets the character used 
  5282.             for separating multiple commands on the same line.  The default is 
  5283.             the ampersand [&]. You cannot use any of the redirection characters 
  5284.             (| > <), or the blank, tab, comma, or equal sign as the command 
  5285.             separator.  This example changes the COMPOUND character to a tilde 
  5286.             [~]: 
  5287.  
  5288.                                 [c:\] setdos /c~
  5289.  
  5290.             If you want to share batch files or aliases between 4DOS or 4OS2 
  5291.             and Take Command, see the %+ variable, which retrieves the current 
  5292.             command separator, and 4DOS, 4OS2, 4DOS/NT and Take Command 
  5293.             Compatibility for details on using compatible command separators 
  5294.             for all the products you use.  Also see the CommandSep directive. 
  5295.  
  5296.     /D      (Descriptions) The DESCRIPTIONS option controls whether file 
  5297.             processing commands like COPY, DEL, MOVE, and REN process file 
  5298.             descriptions along with the files they belong to.  /D1 turns 
  5299.             description processing on, which is the default.  /D0 turns 
  5300.             description processing off.  Also see the Descriptions directive. 
  5301.  
  5302.             You can also use /D to change the description file name, by placing 
  5303.             the new name (rather than a "0" or "1"), in double quotes, 
  5304.             immediately after the /D.  Use this option with caution, because 
  5305.             changing the name from the default will make it difficult to 
  5306.             transfer file descriptions to another system.  Also see the 
  5307.             DescriptionName directive. 
  5308.  
  5309.     /E      (Escape character) The ESCAPE option sets the character used to 
  5310.             suppress the normal meaning of the following character.  Any 
  5311.             character following the escape character will be passed unmodified 
  5312.             to the command.  The default escape character for Take Command is a 
  5313.             caret [^]. You cannot use any of the redirection characters (| > <) 
  5314.             or the blank, tab, comma, or equal sign as the escape character. 
  5315.             Certain characters (b, c, e, f, n, r, s, and t) have special 
  5316.             meanings when immediately preceded by the escape character. 
  5317.  
  5318.             If you want to share batch files or aliases between 4DOS, 4OS2, 
  5319.             4DOS/NT, and Take Command, see the %= variable, which retrieves the 
  5320.             current escape character, and 4DOS, 4OS2, 4DOS/NT and Take Command 
  5321.             Compatibility for details on using compatible escape characters for 
  5322.             all the products you use.  Also see the EscapeChar directive. 
  5323.  
  5324.     /F      (Format for @EVAL) The FORMAT option lets you set default decimal 
  5325.             precision for the @EVAL variable function. The maximum precision is 
  5326.             16 digits to the left of the decimal point and up to 8 digits to 
  5327.             the right of the decimal point.  By default, the minimum precision 
  5328.             to the right of the decimal point is 0.  You can set both the 
  5329.             minimum and maximum number of digits to the right of the decimal 
  5330.             point with the FORMAT option. 
  5331.  
  5332.             The general form of this option is /Fx.y, where the x value sets 
  5333.             the minimum number of digits to the right of the decimal place and 
  5334.             the y value sets the maximum number of digits.  Both values can 
  5335.             range from 0 to 8; if x is greater than y, it is ignored.  You can 
  5336.             specify either or both values:  /F2.5, /F2, and /F.5 are all valid 
  5337.             entries. See the EvalMax and EvalMin directives to set the 
  5338.             precision when Take Command starts; see the @EVAL function if you 
  5339.             want to set the precision for a single computation. 
  5340.  
  5341.     /I      (Internal) The INTERNAL option allows you to disable or enable 
  5342.             internal commands.  To disable a command, precede the command name 
  5343.             with a minus [-].  To re-enable a command, precede it with a plus 
  5344.             [+]. For example, to disable the internal LIST command to force 
  5345.             Take Command to use an external command: 
  5346.  
  5347.                                 [c:\] setdos /i-list
  5348.  
  5349.     /M      (Mode) The MODE option controls the initial line editing mode.  To 
  5350.             start in overstrike mode at the beginning of each command line, use 
  5351.             /M0 (the default).  To start in insert mode, use /M1.  Also see the 
  5352.             EditMode directive. 
  5353.  
  5354.     /N      (No clobber) The NOCLOBBER option controls output redirection). 
  5355.             /N0 means existing files will be overwritten by output redirection 
  5356.             (with >) and that appending (with >>) does not require the file to 
  5357.             exist already.  This is the default.  /N1 means existing files may 
  5358.             not be overwritten by output redirection, and that when appending 
  5359.             the output file must exist.  A /N1 setting can be overridden with 
  5360.             the [!] character.  If you use /N1, you may have problems with a 
  5361.             few unusual programs that shell out to run a command with 
  5362.             redirection, and expect to be able to overwrite an existing file. 
  5363.             Also see the NoClobber directive . 
  5364.  
  5365.     /P      (Parameter character) This option sets the character used after a 
  5366.             percent sign to specify all or all remaining command-line arguments 
  5367.             in a batch file or alias (e.g., %$ or %n$). The default for Take 
  5368.             Command is the dollar sign [$].  If you want to share batch files 
  5369.             or aliases between 4DOS, 4OS2, 4DOS/NT, and Take Command, see 4DOS, 
  5370.             4OS2, 4DOS/NT and Take Command Compatibility for details on 
  5371.             selecting compatible parameter characters for all the products you 
  5372.             use.  Also see the ParameterChar directive. 
  5373.  
  5374.     /S      (Shape) The SHAPE option sets the cursor width.  The format is 
  5375.             /So:i where o is the width for overstrike mode, and i is the width 
  5376.             for insert mode.  The width is entered as a percentage of the total 
  5377.             character width.  The default values are 100:15 (a 100% or block 
  5378.             cursor for overstrike mode, and a 15% or thin line cursor for 
  5379.             insert mode).  Because of the way video drivers remap the cursor 
  5380.             shape, you may not get a smooth progression in the cursor size from 
  5381.             0% - 100%.  To disable the cursor, enter /S0:0. To prevent all 
  5382.             cursor modification, enter /S-1:-1. Also see the CursorOver and 
  5383.             CursorIns directives. 
  5384.  
  5385.     /U      (Upper) The UPPER option controls the default case (upper or lower) 
  5386.             for filenames displayed by internal commands like COPY and DIR. /U0 
  5387.             displays file names in lower case (the default). /U1 displays file 
  5388.             names in the traditional upper case.  Also see the UpperCase 
  5389.             directive . 
  5390.  
  5391.             On drives which support long file names the /U setting is ignored, 
  5392.             and file names are displayed in the case in which they are stored. 
  5393.  
  5394.     /V      (Verbose) The VERBOSE option controls the default for command 
  5395.             echoing in batch files.  /V0 disables echoing of batch file 
  5396.             commands unless ECHO is explicitly set ON.  /V1, the default 
  5397.             setting, enables echoing of batch file commands unless ECHO is 
  5398.             explicitly set OFF.  Also see the BatchEcho directive. 
  5399.  
  5400.     /V2     forces echoing of all batch file commands, even if ECHO is set OFF 
  5401.             or the line begins with an "@".  This allows you to turn echoing on 
  5402.             for a batch file without editing the batch file and removing the 
  5403.             ECHO OFF command(s) within it.  /V2 is intended for debugging, and 
  5404.             can be set with SETDOS, but not with the BatchEcho directive in 
  5405.             TCMDOS2.INI. 
  5406.  
  5407.     /X[+|-]n(expansion and special characters): This option enables and 
  5408.             disables alias and environment variable expansion, and controls 
  5409.             whether special characters have their usual meaning or are treated 
  5410.             as text.  It is most often used in batch files to process text 
  5411.             strings which may contain special characters. 
  5412.  
  5413.             The features enabled or disabled by /X are numbered.  All features 
  5414.             are enabled when Take Command starts, and you can re-enable all 
  5415.             features at any time by using /X0.  To disable a particular 
  5416.             feature, use /X-n, where n is the feature number from the list 
  5417.             below.  To re-enable the feature, use /X+n.  To enable or disable 
  5418.             multiple individual features, list their numbers in sequence after 
  5419.             the  or+- (e.g. /X- 345 to disable features 3, 4, and 5). 
  5420.  
  5421.             The features are: 
  5422.  
  5423.               1  All alias expansion. 
  5424.               2  Nested alias expansion only. 
  5425.               3  All variable expansion (environment variables and batch and 
  5426.             alias parameters) 
  5427.               4  Nested variable expansion only. 
  5428.               5  Multiple commands, conditional commands, and piping 
  5429.               6  Redirection 
  5430.               7  Quoting (double quotes and back quotes) and square brackets 
  5431.               8  Escape character. 
  5432.  
  5433.             If nested alias expansion is disabled, the first alias of a command 
  5434.             is expanded but any aliases it invokes are not expanded.  If nested 
  5435.             variable expansion is disabled, each variable is expanded once, but 
  5436.             variables containing the names of other variables are not expanded 
  5437.             further. 
  5438.  
  5439.             For example, to disable all features except alias expansion while 
  5440.             you are processing a text file containing special characters: 
  5441.  
  5442.                                 setdos /x-35678
  5443.                                 ... [perform text processing here]
  5444.                                 setdos /x0
  5445.  
  5446.     /Y      (Single step) /Y1 enables single-stepping through a batch file. 
  5447.             Each command is displayed on the screen along with a Y/N/R (yes / 
  5448.             no / remainder) prompt.  Press Y to execute the command, N to omit 
  5449.             the command and go on to the next, or R or Esc to execute the 
  5450.             remainder of the batch file (up to the next SETDOS /Y1 command). 
  5451.             You may also press Ctrl-C or Ctrl-Break to terminate the batch 
  5452.             file. 
  5453.  
  5454.             Batch file single stepping is disabled each time Take Command 
  5455.             returns to the command prompt. This means you cannot enter the 
  5456.             SETDOS /Y1 command at the prompt, press Enter, and start a batch 
  5457.             file in single step mode at the next prompt.  However you can 
  5458.             enable single step operation and run a batch file from the prompt 
  5459.             if you enter both commands on one line. For example, this command 
  5460.             runs FILECOMP.BTM with single step enabled: 
  5461.  
  5462.                                 [c:\] setdos /y1 & filecomp.btm
  5463.  
  5464.  
  5465. ΓòÉΓòÉΓòÉ 3.72. SETLOCAL - Save the environment ΓòÉΓòÉΓòÉ
  5466.  
  5467.  Purpose:    Save a copy of the current disk drive, directory, environment, and 
  5468.              alias list. 
  5469.  
  5470.  Format:     SETLOCAL 
  5471.  
  5472.  See also:  ENDLOCAL. 
  5473.  
  5474.  Usage: 
  5475.  
  5476.  SETLOCAL is used in batch files to save the default disk drive and directory, 
  5477.  the environment, and the alias list to a reserved block of memory.  You can 
  5478.  then change their values and later restore the original values with the 
  5479.  ENDLOCAL command. 
  5480.  
  5481.  For example, this batch file fragment saves everything, removes all aliases so 
  5482.  that user aliases will not affect batch file commands, changes the disk and 
  5483.  directory, modifies a variable, runs a program, and then restores the original 
  5484.  values: 
  5485.  
  5486.           setlocal
  5487.           unalias *cdd d:\test
  5488.           set path=c:\;c:\dos;c:\util
  5489.           rem run some program here
  5490.           endlocal
  5491.  
  5492.  SETLOCAL and ENDLOCAL are not nestable within a batch file. However, you can 
  5493.  have multiple SETLOCAL / ENDLOCAL pairs within a batch file, and nested batch 
  5494.  files can each have their own SETLOCAL / ENDLOCAL.  You cannot use SETLOCAL in 
  5495.  an alias or at the command line. 
  5496.  
  5497.  An ENDLOCAL is performed automatically at the end of a batch file if you 
  5498.  forget to do so.  If you invoke one batch file from another without using 
  5499.  CALL, the first batch file is terminated, and an automatic ENDLOCAL is 
  5500.  performed.  The second batch file inherits the drive, directory, aliases, and 
  5501.  environment variables as they were prior to any unterminated SETLOCAL. 
  5502.  
  5503.  
  5504. ΓòÉΓòÉΓòÉ 3.73. SHIFT - Shift batch parameters ΓòÉΓòÉΓòÉ
  5505.  
  5506.  Purpose:    Allows the use of more than 127 parameters in a batch file. 
  5507.  
  5508.  Format:     SHIFT [n ] 
  5509.  
  5510.              n :  Number of positions to shift. 
  5511.  
  5512.  Usage: 
  5513.  
  5514.  SHIFT is provided for compatibility with older batch files, where it was used 
  5515.  to access more than 10 parameters.  Take Command supports 128 parameters (%0 
  5516.  to %127), so you may not need to use SHIFT for batch files running exclusively 
  5517.  under JP Software command processors. 
  5518.  
  5519.  SHIFT moves each of the batch file parameters n positions to the left.  The 
  5520.  default value for n is 1.  SHIFT 1 moves the parameter in %1 to position %0, 
  5521.  the parameter in %2 becomes %1, etc.  You can reverse a SHIFT by giving a 
  5522.  negative value for n (i.e., after SHIFT -1, the former %0 is restored, %0 
  5523.  becomes %1, %1 becomes %2, etc.). 
  5524.  
  5525.  SHIFT also affects the parameters %n$ (command-line tail) and %# (number of 
  5526.  command arguments). 
  5527.  
  5528.  
  5529. ΓòÉΓòÉΓòÉ 3.74. START - Start application in new session ΓòÉΓòÉΓòÉ
  5530.  
  5531.  Purpose:    Start a program in another session or window. 
  5532.  
  5533.  Format:     START ["program title "] [/B[G] /C /DOS[=optfile ] /F[G] /FS /I 
  5534.              /ICON=iconfile /INV /K /L /LA /LD /LH /MAX /MIN /N /PGM progname 
  5535.              /PM /POS=x,y,width,height /TTY /WAIT /WIN /WIN3[=optfile ] 
  5536.              /WIN3S[=optfile ]] [command ] 
  5537.  
  5538.              program title :  Title to appear on title bar. 
  5539.              optfile :  Option settings file. 
  5540.              iconfile :  Name of icon (.ICO ) file. 
  5541.              progname :  Program name (not the session name). 
  5542.              path :  Startup directory. 
  5543.              command :  Command to be executed. 
  5544.  
  5545.              /B[G] (background session)      /LH (local history list) 
  5546.              /C(lose when done)              /MAX(imized) 
  5547.              /DOS (DOS session)              /MIN(imized) 
  5548.              /F[G] (foreground session)      /N(o command processor) 
  5549.              /FS (full screen)               /PGM (program name) 
  5550.              /I(nherit environment)          /PM (PM application) 
  5551.              /ICON (.ICO file)               /POS(ition of window) 
  5552.              /INV(isible)                    /TTY (run in TCMD window) 
  5553.              /K(eep when done)               /WAIT(for session to finish) 
  5554.              /L(ocal lists)                  /WIN (dowed session) 
  5555.              /LA (local aliases)             /WIN3 (Windows enhanced mode) 
  5556.              /LD (local dir history)         /WIN3S (Windows standard mode) 
  5557.  
  5558.  See also:  DETACH. 
  5559.  
  5560.  Usage: 
  5561.  
  5562.  START is used to begin a new OS/2 session, and optionally run a program in 
  5563.  that session.  If you use START with no parameters, it will begin a new Take 
  5564.  Command session.  If you add a command, START will begin a new session or 
  5565.  window and execute that command. 
  5566.  
  5567.  The program title, if it is included, will appear on the title bar, and on the 
  5568.  OS/2 Window List.  The program title must be enclosed in quotation marks and 
  5569.  cannot exceed 60 characters.  If the program title is omitted, the program 
  5570.  name will be used as the title. 
  5571.  
  5572.  START offers a large number of switches to control the session you start.  In 
  5573.  most cases you need only a few switches to accomplish what you want.  The list 
  5574.  below summarizes the most commonly used START options, and how you can use 
  5575.  them to control the way a session is started: 
  5576.  
  5577.         /MAX, /MIN, and /POS allow you to start an application in a maximized 
  5578.         window, a minimized window, or a window with a specified position and 
  5579.         size.  The default is to let the operating system choose the position 
  5580.         and size of the window. 
  5581.  
  5582.         /C allows you to close the session when the command is finished (the 
  5583.         default for DOS and OS/2 Presentation Manager sessions); /K allows you 
  5584.         to keep the session open and go to a prompt (the default for OS/2 
  5585.         character mode sessions). 
  5586.  
  5587.         /BG and /FG allow you to start the session in the background (does not 
  5588.         respond to keystrokes until selected) or foreground (responds to 
  5589.         keystrokes until deselected).  /FG is the default if /DOS, /FS, /WIN, 
  5590.         or /PM is used; otherwise, /BG is the default. 
  5591.  
  5592.         /FS and /WIN control whether a character-mode session is started in 
  5593.         full-screen or windowed mode. 
  5594.  
  5595.  START determines the application type automatically and starts the session in 
  5596.  the appropriate mode:  OS/2, Windows, DOS, full-screen, windowed, or 
  5597.  Presentation Manager. 
  5598.  
  5599.  START gives you some flexibility in determining the session mode. For example, 
  5600.  if the command is the name of a batch file (either a .BTM or .CMD file), you 
  5601.  can use the /FS or /WIN options to run the batch file as part of a new 
  5602.  command-line (4OS2 or CMD.EXE) session in either full-screen or windowed mode. 
  5603.  
  5604.  However, you cannot start a session in a mode that is inappropriate for the 
  5605.  application type.  A DOS application cannot be run as part of a Presentation 
  5606.  Manager session, for example, even if you use the /PM switch. Invalid or 
  5607.  conflicting options will be ignored. Take Command will always attempt to run 
  5608.  the command in the appropriate type of session. 
  5609.  
  5610.  If the program is a DOS application or .BAT file, Take Command will start a 
  5611.  new DOS session to run the program or batch file. The DOS session will close 
  5612.  itself automatically as soon as the program or batch file ends, unless /K is 
  5613.  used.  If you want the session to wait for a keystroke before it closes 
  5614.  itself, you can use the syntax: 
  5615.  
  5616.           [c:\] start /DOS command ^^ pause
  5617.  
  5618.  (Because the caret [^] is the default Take Command for OS/2 escape character, 
  5619.  two carets must be used in order to pass one on to 4DOS, where the caret is 
  5620.  the command separator.) 
  5621.  
  5622.  If you want to start a DOS command-line session you can use the command: 
  5623.  
  5624.           [c:\] start /DOS
  5625.  
  5626.  You can specify settings for DOS and Windows sessions by using a settings 
  5627.  options file, and loading it with the /DOS=, /WIN3=, or /WIN3S= option.  This 
  5628.  allows you to start DOS and Windows sessions with specific settings without 
  5629.  creating a desktop object and modifying the settings manually.  Before using 
  5630.  this capability you should read the description of it under /DOS= (below) very 
  5631.  carefully, since errors in the settings file can occasionally hang your 
  5632.  system. 
  5633.  
  5634.  Options: 
  5635.  
  5636.     /BG         (BackGround session) The session is started as a background 
  5637.                 session. /BG may be abbreviated to /B. 
  5638.  
  5639.     /C          (Close) The session or window is closed when the application 
  5640.                 ends. 
  5641.  
  5642.     /DOS[=filename] (DOS session) Start a DOS session. 
  5643.  
  5644.                 If you include the =filename, OS/2 will load DOS settings from 
  5645.                 the specified file. 
  5646.  
  5647.                 Starting a session with specific DOS settings is an 
  5648.                 undocumented feature which was implemented within OS/2 with 
  5649.                 little error checking.  It is included in START because it 
  5650.                 substantially eases a complex task, but you must experiment 
  5651.                 carefully to ensure that the settings you select will work 
  5652.                 properly on the systems on which you plan to use them. 
  5653.                 Incorrect settings may be ignored, but they may also hang your 
  5654.                 session or stop the entire system.  Be sure your experiments 
  5655.                 are not conducted while critical tasks are in process. 
  5656.  
  5657.                 Each line in the file must have a name, an equal sign [=], and 
  5658.                 a value.  The names are those shown in OS/2's DOS Settings 
  5659.                 dialog box.  Do not use spaces on either side of the equal 
  5660.                 sign. 
  5661.  
  5662.                 The names in the DOS Settings dialog box will vary depending on 
  5663.                 the device drivers and other settings in your CONFIG.SYS file, 
  5664.                 though many are available on all systems.  You must ensure that 
  5665.                 the names you use are valid for the systems on which you use 
  5666.                 them.  For example, if you replace IBM's COM.SYS and VCOM.SYS 
  5667.                 with different communications drivers, the COM_ settings will 
  5668.                 probably not be valid for the new drivers.  If you have a 
  5669.                 settings file which contains settings defined by a particular 
  5670.                 driver, and use it on a system where the corresponding driver 
  5671.                 is not loaded, the results are undefined. 
  5672.  
  5673.                 The values in your settings file must be numeric for settings 
  5674.                 which show a numeric value under DOS Settings (e.g., 
  5675.                 DOS_FILES=30), and must be text strings for settings shown with 
  5676.                 a string (e.g., DOS_SHELL=C:\4DOS.COM C:\4DOS /P).  Strings 
  5677.                 should be entered without trailing blanks.  For values shown as 
  5678.                 multiple choice on the DOS Settings page you must specify a 
  5679.                 numeric value, typically "0" for Off and 1 for On (e.g., 
  5680.                 DOS_HIGH=1).  Items with choices other than Off and On may use 
  5681.                 different values, or may not work at all; experimentation is 
  5682.                 usually required to find out what works.  Attempting to use 
  5683.                 strings for choice items (e.g., DOS_HIGH=ON) will not work, and 
  5684.                 can hang your system.  This is due to the internal operation of 
  5685.                 OS/2, and is not a problem in Take Command. 
  5686.  
  5687.                 A typical DOS settings file might look like this: 
  5688.  
  5689.                                         DOS_FILES=30
  5690.                                         DOS_HIGH=1
  5691.                                         DOS_SHELL=C:\4DOS\4DOS.COM C:\4DOS /P
  5692.                                         MOUSE_EXCLUSIVE_ACCESS=0
  5693.                                         VIDEO_FASTPASTE=1
  5694.  
  5695.                 You can include comments in a settings file by beginning any 
  5696.                 line with a colon [:]. 
  5697.  
  5698.     /FG         (ForeGround session) Start the session as the foreground 
  5699.                 session.  /FG may be abbreviated to /F. 
  5700.  
  5701.     /FS         (Full Screen) Start the session as a full-screen session. 
  5702.  
  5703.     /I          (Inherit environment) Inherit the default environment specified 
  5704.                 in CONFIG.SYS, if any, rather than the current environment. 
  5705.  
  5706.     /ICON=filename: Use the specified icon file.  If you don't use /ICON, Take 
  5707.                 Command will look for an .ICO file with the same file name and 
  5708.                 in the same directory as the program file.  Some versions of 
  5709.                 OS/2 may ignore this option and use the default icon for the 
  5710.                 session.  If you encounter this problem, check whether an 
  5711.                 update to OS/2 has been released which addresses it. 
  5712.  
  5713.     /INV        (Invisible) Start the session or window as invisible.  No icon 
  5714.                 will appear and the session will only be accessible through the 
  5715.                 Window List. 
  5716.  
  5717.     /K          (Keep session or window at end) The session or window continues 
  5718.                 after the application program ends.  Use the EXIT command to 
  5719.                 end the session. 
  5720.  
  5721.     /L          (Local lists) Start Take Command with local alias, history, and 
  5722.                 directory history lists.  This option combines the effects of 
  5723.                 /LA, /LD, and /LH (below). 
  5724.  
  5725.     /LA         (Local Alias list) Start Take Command with a local alias list. 
  5726.                 See ALIAS for information on local and global aliases. 
  5727.  
  5728.     /LD         (Local Directory history) Start Take Command with a local 
  5729.                 directory history list.  See Directory History Window for more 
  5730.                 information. 
  5731.  
  5732.     /LH         (Local History list) Start Take Command with a local history 
  5733.                 list. See Command History and Recall for information on local 
  5734.                 and global history lists. 
  5735.  
  5736.     /MAX        (Maximized) Start the session or window maximized. 
  5737.  
  5738.     /MIN        (Minimized) Start the session or window minimized. 
  5739.  
  5740.     /N          Start an OS/2 program directly, without a command processor. 
  5741.                 The command cannot be an internal command or batch file. This 
  5742.                 is the default for PM applications. 
  5743.  
  5744.     /PGM        (Program name) The string following this option is the program 
  5745.                 name.  The first quoted string on the line will be used as the 
  5746.                 session and task list title, and not as the program name. 
  5747.  
  5748.     /PM         (Presentation Manager) Start a program in the PM session. 
  5749.  
  5750.     /POS        (Position) Start the window at the specified screen position. 
  5751.                 The syntax is /POS=x, y, width, height where the values are 
  5752.                 specified in pixels or pels.  x and y refer to the position of 
  5753.                 the bottom left corner of the window relative to the bottom 
  5754.                 left corner of the screen. 
  5755.  
  5756.                 /POS will not be effective for any application which sets its 
  5757.                 own screen size and position.  Because Take Command itself is 
  5758.                 such an application, /POS will have no effect when starting 
  5759.                 another Take Command session. 
  5760.  
  5761.     /TTY        Run an OS/2 console-mode program or a DOS program in the Take 
  5762.                 Command window.  /TTY will only work with applications that get 
  5763.                 their keyboard input from STDIN and write to STDOUT and/or 
  5764.                 STDERR.  For more details see Starting Character-Mode 
  5765.                 Applications.  Take Command always waits for applications 
  5766.                 started with /TTY to finish before returning to the prompt. 
  5767.  
  5768.     /WAIT       Wait for the new session or window to finish before continuing. 
  5769.                 Cannot be used with /WIN3 or /WIN3S. 
  5770.  
  5771.     /WIN        (Windowed) Start the session in a window. 
  5772.  
  5773.     /WIN3[=filename] (Windows enhanced mode) Run the program in an 
  5774.                 enhanced-mode Windows 3.x session.  The session will run 
  5775.                 seamless (on the OS/2 desktop).  To start a Windows application 
  5776.                 in full-screen mode, use /FS rather than /WIN3.  You can 
  5777.                 include an equal sign and the name of an options file to set 
  5778.                 options for the specific session and application (see /DOS= 
  5779.                 above for details).  The setting names in the file should be 
  5780.                 taken from those shown in OS/2's WIN-OS/2 Settings dialog box. 
  5781.  
  5782.     /WIN3S[=filename] (Windows standard mode) Equivalent to /WIN3, but runs the 
  5783.                 program in standard mode rather than enhanced mode. 
  5784.  
  5785.  
  5786. ΓòÉΓòÉΓòÉ 3.75. SHRALIAS - Load or unload SHRALIAS.EXE ΓòÉΓòÉΓòÉ
  5787.  
  5788.  Purpose:    Load or unload SHRALIAS.EXE, which saves shared aliases, history, 
  5789.              and directory history between Take Command sessions. 
  5790.  
  5791.  Format:     SHRALIAS [/U] 
  5792.  
  5793.              /U(nload) 
  5794.  
  5795.  See also:  ALIAS, Command History and Recall, and the Directory History 
  5796.  Window. 
  5797.  
  5798.  Usage: 
  5799.  
  5800.  If you select a global alias, history, or directory history list for Take 
  5801.  Command you can share the list(s) among all copies of Take Command running in 
  5802.  any session.  However, when you close all Take Command sessions the memory for 
  5803.  these global lists is released, and new, empty lists are created the next time 
  5804.  you start Take Command. 
  5805.  
  5806.  SHRALIAS retains one or more of these lists in memory even when no Take 
  5807.  Command session is running, and makes the information in the retained list(s) 
  5808.  available to the next Take Command session that is started. This allows you to 
  5809.  keep your aliases, command history, and directory history between Take Command 
  5810.  sessions (as long as OS/2 is not restarted). 
  5811.  
  5812.  Actual retention of the shared lists is handled by the SHRALIAS.EXE program. 
  5813.  The internal SHRALIAS command is used to load and unload SHRALIAS.EXE. 
  5814.  (SHRALIAS.EXE is distributed as part of Take Command, and must be located in 
  5815.  your Take Command directory, or a directory on your PATH.) 
  5816.  
  5817.  To load SHRALIAS.EXE, enter the SHRALIAS command with no parameters: 
  5818.  
  5819.           [c:\] shralias
  5820.  
  5821.  SHRALIAS.EXE runs as a "detached" process, which means it does not have a 
  5822.  screen display, accept keyboard input, or appear on the OS/2 window list.  It 
  5823.  is shut down automatically when OS/2 shuts down.  You can also unload 
  5824.  SHRALIAS.EXE manually, with SHRALIAS /U: 
  5825.  
  5826.           [c:\] shralias /u
  5827.  
  5828.  Once SHRALIAS.EXE is unloaded any shared alias, history, and directory history 
  5829.  lists will be released when the last copy of Take Command terminates. 
  5830.  
  5831.  Do not attempt to load or unload the SHRALIAS.EXE program directly -- it must 
  5832.  be managed with the SHRALIAS command. 
  5833.  
  5834.  You may find it convenient to invoke SHRALIAS from your TCSTART file.  If you 
  5835.  do, once SHRALIAS.EXE is loaded additional attempts to reload it (for example, 
  5836.  when a second or subsequent Take Command session runs TCSTART) will be 
  5837.  ignored, and will display the informational message "SHRALIAS already loaded". 
  5838.  Similarly, if you attempt to unload SHARLIAS.EXE with the SHRALIAS /U command 
  5839.  and it has not been loaded, Take Command will display the message "SHRALIAS 
  5840.  not loaded". 
  5841.  
  5842.  SHRALIAS must be invoked from a Take Command session which uses at least one 
  5843.  global list.  If you invoke it from a session where the alias list, history 
  5844.  list, and directory history list are all local, it will not be able to find 
  5845.  any shared memory to retain, and will display an error. 
  5846.  
  5847.  Option: 
  5848.  
  5849.     /U      (Unload) Unload SHRALIAS.EXE from memory. 
  5850.  
  5851.  
  5852. ΓòÉΓòÉΓòÉ 3.76. TEE - "Tee" pipe fitting ΓòÉΓòÉΓòÉ
  5853.  
  5854.  Purpose:    Copy standard input to both standard output and a file. 
  5855.  
  5856.  Format:     TEE [/A] file... 
  5857.  
  5858.              file :  One or more files that will receive the "tee-d" output. 
  5859.  
  5860.              /A(ppend) 
  5861.  
  5862.  See also:  Y and the redirection options. 
  5863.  
  5864.  Usage: 
  5865.  
  5866.  TEE is normally used to "split" the output of a program so that you can see it 
  5867.  on the display and also save it in a file.  It can also be used to capture 
  5868.  intermediate output before the data is altered by another program or command. 
  5869.  
  5870.  TEE gets its input from standard input (usually the piped output of another 
  5871.  command or program), and sends out two copies:  one goes to standard output, 
  5872.  the other to the file or files that you specify.  TEE is not likely to be 
  5873.  useful with programs which do not use standard output, because these programs 
  5874.  cannot send output through a pipe. 
  5875.  
  5876.  For example, to search the file DOC for any lines containing the string "Take 
  5877.  Command", make a copy of the matching lines in 4.DAT, sort the lines, and 
  5878.  write them to the output file 4O.DAT: 
  5879.  
  5880.           [c:\] find "Take Command" doc | tee 4.dat | sort > 4o.dat
  5881.  
  5882.  If you are typing at the keyboard to produce the input for TEE, you must enter 
  5883.  a Ctrl-Z to terminate the input. 
  5884.  
  5885.  When using TEE with a pipe under Take Command, the programs on the two ends of 
  5886.  the pipe run simultaneously, not sequentially as in 4DOS. 
  5887.  
  5888.  See Piping for more information on pipes. 
  5889.  
  5890.  Option: 
  5891.  
  5892.     /A      (Append) Append the output to the file(s) rather than overwriting 
  5893.             them. 
  5894.  
  5895.  
  5896. ΓòÉΓòÉΓòÉ 3.77. TEXT - Display text in batch file ΓòÉΓòÉΓòÉ
  5897.  
  5898.  Purpose:    Display a block of text in a batch file. 
  5899.  
  5900.  Format:     TEXT 
  5901.                 . 
  5902.                 . 
  5903.                 . 
  5904.              ENDTEXT 
  5905.  
  5906.  See also:  ECHO, SCREEN, SCRPUT, and VSCRPUT. 
  5907.  
  5908.  Usage: 
  5909.  
  5910.  TEXT can only be used in batch files. 
  5911.  
  5912.  The TEXT command is useful for displaying menus or multi-line messages.  TEXT 
  5913.  will display all subsequent lines in the batch file until terminated by 
  5914.  ENDTEXT.  Both TEXT and ENDTEXT must be entered as the only command on the 
  5915.  line. 
  5916.  
  5917.  To redirect the entire block of text, use redirection on the TEXT command 
  5918.  itself, but not on the actual text lines or the ENDTEXT line.  No environment 
  5919.  variable expansion or other processing is performed on the lines between TEXT 
  5920.  and ENDTEXT; they are displayed exactly as they are stored in the batch file. 
  5921.  
  5922.  You can use a CLS or COLOR command to set the screen color before executing 
  5923.  the TEXT command. 
  5924.  
  5925.  The following batch file fragment displays a simple menu: 
  5926.  
  5927.           @echo off & cls
  5928.           screen 2 0
  5929.           text
  5930.           Enter one of the following:
  5931.           1 - Spreadsheet
  5932.           2 - Word Processing
  5933.           3 - Utilities
  5934.           endtext
  5935.  
  5936.  
  5937. ΓòÉΓòÉΓòÉ 3.78. TIME - Set the system time ΓòÉΓòÉΓòÉ
  5938.  
  5939.  Purpose:    Display or set the current system time. 
  5940.  
  5941.  Format:     TIME [hh [:mm [:ss ]]] [AM | PM] 
  5942.  
  5943.              hh :  The hour (0 - 23). 
  5944.              mm :  The minute (0 - 59). 
  5945.              ss :  The second (0 - 59). 
  5946.  
  5947.  See also:  DATE. 
  5948.  
  5949.  Usage: 
  5950.  
  5951.  If you don't enter any parameters, TIME will display the current system time 
  5952.  and prompt you for a new time.  Press Enter if you don't wish to change the 
  5953.  time; otherwise, enter the new time:. 
  5954.  
  5955.           [c:\] time
  5956.           Thu  Dec 22, 1994  9:30:10
  5957.           New time (hh:mm:ss):
  5958.  
  5959.  TIME defaults to 24-hour format, but you can optionally enter the time in 
  5960.  12-hour format by appending "a", "am", "p", or "pm" to the time you enter. 
  5961.  
  5962.  For example, to enter the time as 9:30 am: 
  5963.  
  5964.           [c:\] time 9:30 am
  5965.  
  5966.  OS/2 adds the system time and date to the directory entry for every file you 
  5967.  create or modify.  If you keep both the time and date accurate, you will have 
  5968.  a record of when you last updated each file. 
  5969.  
  5970.  
  5971. ΓòÉΓòÉΓòÉ 3.79. TIMER - Start or stop a stopwatch ΓòÉΓòÉΓòÉ
  5972.  
  5973.  Purpose:    TIMER is a system stopwatch. 
  5974.  
  5975.  Format:     TIMER [ON] [/1 /2 /3 /S] 
  5976.  
  5977.              ON:  Force the stopwatch to restart 
  5978.  
  5979.              /1 (stopwatch #1)           /3 (stopwatch #3) 
  5980.              /2 (stopwatch #2)           /S(plit) 
  5981.  
  5982.  Usage: 
  5983.  
  5984.  The TIMER command turns a system stopwatch on and off.  When you first run 
  5985.  TIMER, the stopwatch starts: 
  5986.  
  5987.           [c:\] timer
  5988.           Timer 1 on:  12:21:46
  5989.  
  5990.  When you run TIMER again, the stopwatch stops and the elapsed time is 
  5991.  displayed: 
  5992.  
  5993.           [c:\] timer
  5994.           Timer 1 off:  12:21:58
  5995.           Elapsed time: 0:00:12.06
  5996.  
  5997.  There are three stopwatches available (1, 2, and 3) so you can time multiple 
  5998.  overlapping events.  By default, TIMER uses stopwatch #1. 
  5999.  
  6000.  The smallest interval TIMER can measure depends on the operating system you 
  6001.  are using, your hardware, and the interaction between the two.  However, it 
  6002.  should never be greater than .06 second.  The largest interval is 23 hours, 59 
  6003.  minutes, 59.99 seconds. 
  6004.  
  6005.  Options: 
  6006.  
  6007.     /1      Use timer #1 (the default). 
  6008.     /2      Use timer #2. 
  6009.     /3      Use timer #3. 
  6010.     /S      (Split) Display a split time without stopping the timer.  To 
  6011.             display the current elapsed time but leave the timer running: 
  6012.  
  6013.                                 [c:\] timer /s
  6014.                                 Timer 1 elapsed: 0:06:40.63
  6015.  
  6016.     ON:     Start the timer regardless of its previous state (on or off). 
  6017.             Otherwise the TIMER command toggles the timer state (unless /S is 
  6018.             used). 
  6019.  
  6020.  
  6021. ΓòÉΓòÉΓòÉ 3.80. TITLE - Set window title ΓòÉΓòÉΓòÉ
  6022.  
  6023.  Purpose:    Change the window title. 
  6024.  
  6025.  Format:     TITLE "title" 
  6026.  
  6027.              title: The new window title. 
  6028.  
  6029.  See also:  ACTIVATE and WINDOW. 
  6030.  
  6031.  Usage: 
  6032.  
  6033.  TITLE changes the text that appears in the caption bar at the top of the Take 
  6034.  Command window.  It is included for compatibility with traditional 
  6035.  character-mode command processors (like CMD.EXE). You can also change the 
  6036.  window title with the WINDOW command or the ACTIVATE command. 
  6037.  
  6038.  The title text must be enclosed in double quotes.  The quotes will not appear 
  6039.  as part of the actual title. 
  6040.  
  6041.  To change the title of the current window to "Take Command Test": 
  6042.  
  6043.           [c:\] title "Take Command Test"
  6044.  
  6045.  
  6046. ΓòÉΓòÉΓòÉ 3.81. TYPE - Display a file ΓòÉΓòÉΓòÉ
  6047.  
  6048.  Purpose:    Display the contents of the specified file(s). 
  6049.  
  6050.  Format:     TYPE [/A:[[-]rhsda] /L /P] file... 
  6051.  
  6052.              file :  The file or list of files that you want to display. 
  6053.  
  6054.              /A:(ttribute select) 
  6055.              /L(ine numbers) 
  6056.              /P(ause) 
  6057.  
  6058.  See also:  LIST. 
  6059.  
  6060.  File Selection: 
  6061.  
  6062.  Supports extended wildcards, ranges, multiple file names, and include lists. 
  6063.  
  6064.  Usage: 
  6065.  
  6066.  The TYPE command displays a file.  It is normally only useful for displaying 
  6067.  ASCII text files.  Executable files (.COM and .EXE ) and many data files may 
  6068.  be unreadable when displayed with TYPE because they include non-alphanumeric 
  6069.  characters. 
  6070.  
  6071.  To display the files MEMO1 and MEMO2: 
  6072.  
  6073.           [c:\] type /p memo1 memo2
  6074.  
  6075.  You can press Ctrl-S to pause TYPE's display and then any key to continue. 
  6076.  
  6077.  You will probably find LIST to be more useful for displaying files. However, 
  6078.  the TYPE /L command used with redirection is useful if you want to add line 
  6079.  numbers to a file. 
  6080.  
  6081.  Options: 
  6082.  
  6083.     /A      (Attribute select) Select only those files that have the specified 
  6084.             attribute(s) set.  Preceding the attribute character with a hyphen 
  6085.             [-] will select files that do not have that attribute set.  The 
  6086.             colon [:] after /A is required.  The attributes are: 
  6087.  
  6088.                           R  Read-only 
  6089.                           H  Hidden 
  6090.                           S  System 
  6091.                           D  Subdirectory 
  6092.                           A  Archive 
  6093.  
  6094.             If no attributes are listed at all (e.g., TYPE /A: ...), TYPE will 
  6095.             select all files and subdirectories including hidden and system 
  6096.             files.  If attributes are combined, all the specified attributes 
  6097.             must match for a file to be selected.  For example, /A:RHS will 
  6098.             select only those files with all three attributes set. 
  6099.  
  6100.     /L      (Line numbers) Display a line number preceding each line of text. 
  6101.  
  6102.     /P      (Pause) Prompt after displaying each page.  Your options at the 
  6103.             prompt are explained in detail under Page and File Prompts. 
  6104.  
  6105.  
  6106. ΓòÉΓòÉΓòÉ 3.82. UNALIAS - Remove aliases ΓòÉΓòÉΓòÉ
  6107.  
  6108.  Purpose:    Remove aliases from the alias list. 
  6109.  
  6110.  Format:     UNALIAS [/Q] alias... 
  6111.                 or 
  6112.              UNALIAS * 
  6113.  
  6114.              alias :  One or more aliases to remove from memory. 
  6115.  
  6116.              /Q(uiet) 
  6117.  
  6118.  See also:  ALIAS and ESET. 
  6119.  
  6120.  Usage: 
  6121.  
  6122.  Take Command maintains a list of the aliases that you have defined. The 
  6123.  UNALIAS command will remove aliases from that list.  You can remove one or 
  6124.  more aliases by name, or you can delete the entire alias list by using the 
  6125.  command UNALIAS *.  For example, to remove the alias DDIR: 
  6126.  
  6127.           [c:\] unalias ddir
  6128.  
  6129.  To remove all the aliases: 
  6130.  
  6131.           [c:\] unalias *
  6132.  
  6133.  Options: 
  6134.  
  6135.     /Q      (Quiet) Prevents UNALIAS from displaying an error message if one or 
  6136.             more of the aliases does not exist.  This option is most useful in 
  6137.             batch files, for removing a group of aliases when some of the 
  6138.             aliases may not have been defined. 
  6139.  
  6140.  
  6141. ΓòÉΓòÉΓòÉ 3.83. UNSET - Remove environment variables ΓòÉΓòÉΓòÉ
  6142.  
  6143.  Purpose:    Remove variables from the environment. 
  6144.  
  6145.  Format:     UNSET  [/Q] name... 
  6146.                 or 
  6147.              UNSET * 
  6148.  
  6149.              name :  One or more variables to remove from the environment. 
  6150.  
  6151.              /Q(uiet) 
  6152.  
  6153.  See also:  ESET and SET. 
  6154.  
  6155.  Usage: 
  6156.  
  6157.  UNSET removes one or more variables from the environment.  For example, to 
  6158.  remove the variable CMDLINE: 
  6159.  
  6160.           [c:\] unset cmdline
  6161.  
  6162.  If you use the command UNSET *, all of the environment variables will be 
  6163.  deleted: 
  6164.  
  6165.           [c:\] unset *
  6166.  
  6167.  UNSET is often used in conjunction with the SETLOCAL and ENDLOCAL commands in 
  6168.  order to clear the environment of variables that may cause problems for some 
  6169.  applications. 
  6170.  
  6171.  For more information on environment variables, see the SET command and the 
  6172.  general discussion of the environment. 
  6173.  
  6174.  Use caution when removing environment variables, and especially when using 
  6175.  UNSET *.  Many programs will not work properly without certain environment 
  6176.  variables; for example, Take Command uses PATH and CDPATH. 
  6177.  
  6178.  Options: 
  6179.  
  6180.     /Q      (Quiet) Prevents UNSET from displaying an error message if one or 
  6181.             more of the variables does not exist.  This option is most useful 
  6182.             in batch files, for removing a group of variables when some of the 
  6183.             variables may not have been defined. 
  6184.  
  6185.  
  6186. ΓòÉΓòÉΓòÉ 3.84. VER - Display version levels ΓòÉΓòÉΓòÉ
  6187.  
  6188.  Purpose:    Display the current command processor and operating system 
  6189.              versions. 
  6190.  
  6191.  Format:     VER [/R] 
  6192.  
  6193.              /R(evision level) 
  6194.  
  6195.  Usage: 
  6196.  
  6197.  Version numbers consist of a one-digit major version number, a period, and a 
  6198.  one- or two-digit minor version number.  The VER command displays both version 
  6199.  numbers: 
  6200.  
  6201.           [c:\] ver
  6202.           Take Command for OS/2 1.0   OS/2 Version is 3.0
  6203.  
  6204.  Option: 
  6205.  
  6206.     /R      (Revision level) Display the Take Command and OS/2 internal 
  6207.             revision levels, plus your Take Command serial number and 
  6208.             registered name. 
  6209.  
  6210.  
  6211. ΓòÉΓòÉΓòÉ 3.85. VERIFY - Disk write verification ΓòÉΓòÉΓòÉ
  6212.  
  6213.  Purpose:    Enable or disable disk write verification or display the 
  6214.              verification state. 
  6215.  
  6216.  Format:     VERIFY [ON | OFF] 
  6217.  
  6218.  Usage: 
  6219.  
  6220.  OS/2 maintains an internal verify flag.  When the flag is on, OS/2 attempts to 
  6221.  verify each disk write by making sure that the data written to the disk can be 
  6222.  read back successfully into the computer.  It does not compare the data 
  6223.  written with the data on disk. 
  6224.  
  6225.  
  6226. ΓòÉΓòÉΓòÉ 3.86. VOL - Display drive label ΓòÉΓòÉΓòÉ
  6227.  
  6228.  Purpose:    Display disk volume label(s). 
  6229.  
  6230.  Format:     VOL [d :] ... 
  6231.  
  6232.              d:  The drive or drives to search for labels. 
  6233.  
  6234.  Usage: 
  6235.  
  6236.  Each disk may have a volume label, created when the disk is formatted or with 
  6237.  the external LABEL command.  Also, every floppy disk formatted with DOS 
  6238.  version 4.0 or above or with OS/2 has a volume serial number. 
  6239.  
  6240.  The VOL command will display the volume label and, if available, the volume 
  6241.  serial number of a disk volume.  If the disk doesn't have a volume label, VOL 
  6242.  will report that it is "unlabeled."  If you don't specify a drive, VOL 
  6243.  displays information about the current drive: 
  6244.  
  6245.           [c:\] vol
  6246.           Volume in drive C: is MYHARDDISK
  6247.  
  6248.  If available, the volume serial number will appear after the drive label or 
  6249.  name. 
  6250.  
  6251.  To display the disk labels for drives A and B: 
  6252.  
  6253.           [c:\] vol a: b:
  6254.           Volume in drive A: is unlabeled
  6255.           Volume in drive B: is BACKUP_2
  6256.  
  6257.  
  6258. ΓòÉΓòÉΓòÉ 3.87. VSCRPUT - Display text in color vertically ΓòÉΓòÉΓòÉ
  6259.  
  6260.  Purpose:    Display text vertically in the specified color. 
  6261.  
  6262.  Format:     VSCRPUT row col [BRIght] fg ON [BRIght] bg text 
  6263.  
  6264.              row :  Starting row number. 
  6265.              col :  Starting column number. 
  6266.              fg :  Foreground text color. 
  6267.              bg :  Background text color. 
  6268.              text :  The text to display. 
  6269.  
  6270.  See also:  SCRPUT. 
  6271.  
  6272.  Usage: 
  6273.  
  6274.  VSCRPUT writes text vertically on the screen rather than horizontally. Like 
  6275.  the SCRPUT command, it uses the colors you specify to write the text.  VSCRPUT 
  6276.  can be used for simple graphs and charts generated by batch files.  It always 
  6277.  leaves the cursor in its current position. 
  6278.  
  6279.  The row and column are zero-based, so on a standard 25 line by 80 column 
  6280.  display, valid rows are 0 - 24 and valid columns are 0 - 79.  You can also 
  6281.  specify the row and column as offsets from the current cursor position.  Begin 
  6282.  the value with a plus sign [+] to move down the specified number of rows or to 
  6283.  the right the specified number of columns before displaying text, or with a 
  6284.  minus sign [-] to move up or to the left. 
  6285.  
  6286.  VSCRPUT checks for a valid row and column, and displays a "Usage" error 
  6287.  message if either value is out of range. 
  6288.  
  6289.  
  6290. ΓòÉΓòÉΓòÉ 3.88. WINDOW - Change the window state or title ΓòÉΓòÉΓòÉ
  6291.  
  6292.  Purpose:    Minimize or maximize the current window, restore the default 
  6293.              window size, or change the window title. 
  6294.  
  6295.  Format:     WINDOW [MIN | MAX | RESTORE | /POS=x,y,width,height | "title "] 
  6296.  
  6297.              title :  A new title for the window. 
  6298.  
  6299.              /POS(ition) 
  6300.  
  6301.  Usage: 
  6302.  
  6303.  WINDOW is used to control the appearance and title of the current window. 
  6304.  WINDOW MIN reduces the window to an icon, WINDOW MAX enlarges it to its 
  6305.  maximum size, and WINDOW RESTORE returns the window to its default size and 
  6306.  location on the desktop. 
  6307.  
  6308.  You can use the /POS option to set the location and size of the window on the 
  6309.  desktop.  The row and column values of the /POS option select the window's 
  6310.  origin (from the bottom left of the screen) while the width and height values 
  6311.  determine its size. 
  6312.  
  6313.  If you specify a new title, the title text must be enclosed in double quotes. 
  6314.  The quotes will not appear as part of the actual title. 
  6315.  
  6316.  Option: 
  6317.  
  6318.     /POS    (Position) Set the window screen position and size.  The syntax is 
  6319.             /POS=x, y, width, height, where the values are specified in pixels 
  6320.             or pels.  x and y refer to the position of the bottom left corner 
  6321.             of the window relative to the bottom left corner of the screen. 
  6322.  
  6323.  
  6324. ΓòÉΓòÉΓòÉ 3.89. Y - "Y" pipe fitting ΓòÉΓòÉΓòÉ
  6325.  
  6326.  Purpose:    Copy standard input to standard output, and then copy the 
  6327.              specified file(s) to standard output. 
  6328.  
  6329.  Format:     Y file ... 
  6330.  
  6331.              file :  The file or list of files to send to standard output. 
  6332.  
  6333.  See also:  TEE. 
  6334.  
  6335.  Usage: 
  6336.  
  6337.  The Y command copies input from standard input (usually the keyboard) to 
  6338.  standard output (usually the screen).  Once the input ends, the named files 
  6339.  are appended to standard output. 
  6340.  
  6341.  For example, to get text from standard input, append the files MEMO1 and MEMO2 
  6342.  to it, and send the output to MEMOS: 
  6343.  
  6344.           [c:\] y memo1 memo2 > memos
  6345.  
  6346.  The Y command is most useful if you want to add redirected data to the 
  6347.  beginning of a file instead of appending it to the end.  For example, this 
  6348.  command copies the output of DIR, followed by the contents of  the file 
  6349.  DIREND, to the file DIRALL: 
  6350.  
  6351.           [c:\] dir | y dirend > dirall
  6352.  
  6353.  If you are typing at the keyboard to produce input text for Y, you must enter 
  6354.  a Ctrl-Z to terminate the input. 
  6355.  
  6356.  When using Y with a pipe you must take into account that the programs on the 
  6357.  two ends of the pipe run simultaneously, not sequentially as they would under 
  6358.  4DOS. 
  6359.  
  6360.  See Piping for more information on pipes. 
  6361.  
  6362.  
  6363. ΓòÉΓòÉΓòÉ 4. Using Take Command ΓòÉΓòÉΓòÉ
  6364.  
  6365. Take Command is both a collection of commands and a set of features which make 
  6366. your computer easier to use.  This section explains the Take Command features 
  6367. that are not directly related to individual commands. 
  6368.  
  6369.  
  6370. ΓòÉΓòÉΓòÉ 4.1. Conventions ΓòÉΓòÉΓòÉ
  6371.  
  6372. This information about conventions that are used throughout Take Command: 
  6373.  
  6374.     Colors and color names 
  6375.     Color-coded directories 
  6376.     Keys and key names 
  6377.  
  6378. These topics are combined here so that they will be easy to find when you need 
  6379. to refer to them.  You will find cross references to this section throughout 
  6380. the help system. 
  6381.  
  6382.  
  6383. ΓòÉΓòÉΓòÉ 4.1.1. Colors and Color Names ΓòÉΓòÉΓòÉ
  6384.  
  6385. You can use color names in several of the directives in the TCMDOS2.INI file 
  6386. and in many commands. The general form of a color name is: 
  6387.  
  6388.     [BRIght] fg ON [BRIght] bg 
  6389.  
  6390. where fg is the foreground or text color, and bg is the background color. 
  6391.  
  6392. The available colors are: 
  6393.  
  6394.         Black    Blue    Green    Red
  6395.         Magenta  Cyan    Yellow   White
  6396.  
  6397. Color names and the word BRIght may be shortened to the first 3 letters. 
  6398.  
  6399. You can also specify colors by number instead of by name.  The numbers are most 
  6400. useful in potentially long INI file directives like ColorDIR.  Take Command 
  6401. recognizes these color numbers: 
  6402.  
  6403.         0 - Black       8 - Gray (bright black)
  6404.         1 - Blue        9 - Bright blue
  6405.         2 - Green      10 - Bright green
  6406.         3 - Cyan       11 - Bright cyan
  6407.         4 - Red        12 - Bright red
  6408.         5 - Magenta    13 - Bright magenta
  6409.         6 - Yellow     14 - Bright yellow
  6410.         7 - White      15 - Bright white
  6411.  
  6412. Use one number to substitute for the [BRIght] fg portion of the color name, and 
  6413. a second to substitute for the [BRIght] bg portion.  For example, instead of 
  6414. bright cyan on blue you could use 11 on 1 to save space in a ColorDir 
  6415. specification. 
  6416.  
  6417.  
  6418. ΓòÉΓòÉΓòÉ 4.1.2. Color-Coded Directories ΓòÉΓòÉΓòÉ
  6419.  
  6420. The DIR command can display each file name in a different color, depending on 
  6421. the file's extension. 
  6422.  
  6423. To choose the DIR display colors, you must either use the SET command to create 
  6424. an environment variable called COLORDIR, or use the ColorDir directive in your 
  6425. .INI file.  If you do not use the COLORDIR variable or the ColorDir directive, 
  6426. DIR will use the default screen colors. 
  6427.  
  6428. If you use both the COLORDIR variable and the ColorDir directive, the 
  6429. environment variable will override the settings in your .INI file.  You may 
  6430. find it useful to use the COLORDIR variable for experimenting and then set 
  6431. permanent directory colors with the ColorDir directive. 
  6432.  
  6433. The format for both the COLORDIR environment variable and the ColorDir 
  6434. directive in the .INI file is: 
  6435.  
  6436.         ext... :ColorName; ...
  6437.  
  6438. where "ext" is a file extension (which may include wildcards) or one of the 
  6439. following file types: 
  6440.  
  6441.         DIRS      Directories
  6442.         RDONLY    Read-only files
  6443.         HIDDEN    Hidden files
  6444.         SYSTEM    System files
  6445.         ARCHIVE   Files modified since the last backup
  6446.  
  6447. and "ColorName" is any valid color name (see Colors). 
  6448.  
  6449. Unlike most color specifications, the background portion of the color name may 
  6450. be left out for directory colors.  If you don't specify a background color, DIR 
  6451. will use the current screen background color. 
  6452.  
  6453. For example, to display the .COM and .EXE files in red on the current 
  6454. background, the .C and .ASM files in bright cyan on the current background, and 
  6455. the read-only files in bright green on white (this should be entered on one 
  6456. line): 
  6457.  
  6458.         [c:\] set colordir=com exe:red;c asm:bri cyan;rdonly:bri gre on whi
  6459.  
  6460. Extended wildcards (for example "BA[KXC]" for .BAK, .BAX, and .BAC files) can 
  6461. be used in directory color specifications. 
  6462.  
  6463. You can specify files with any extension using the * wildcard, and files with 
  6464. no extension using a space.  For example, the following specification displays 
  6465. files with no extension in red, .TXT files in blue, and all other files in 
  6466. green: 
  6467.  
  6468.         [c:\] set colordir= :red;txt:blu;*:gre
  6469.  
  6470. If the extension or type of a file matches an extension or type listed in your 
  6471. color specification, the remainder of the colors are ignored for that file. 
  6472. You may need to take this into account in determining the order of extensions 
  6473. and file types in your COLORDIR setting.  For example, you might try this 
  6474. setting to display all .COM and .EXE files in red, and all other files whose 
  6475. extension starts with a "C" in green: 
  6476.  
  6477.         [c:\] set colordir=c*:green;com exe:red
  6478.  
  6479. However in this case the .COM files will be displayed in green, because they 
  6480. match the "c*", and the ".com" later on the line is ignored.  To correct this 
  6481. problem, change the line to read: 
  6482.  
  6483.         [c:\] set colordir=com exe:red;c*:green
  6484.  
  6485.  
  6486. ΓòÉΓòÉΓòÉ 4.1.3. Keys and Key Names ΓòÉΓòÉΓòÉ
  6487.  
  6488. Key names are used to define keystroke aliases, and in several TCMDOS2.INI 
  6489. directives. The format of a key name is the same in both uses: 
  6490.  
  6491.         [Prefix-]Keyname
  6492.  
  6493. The key prefix can be left out, or it can be any one of the following : 
  6494.  
  6495.         Alt       followed by A - Z, 0 - 9, F1 - F12, or Bksp
  6496.         Ctrl      followed by A - Z, F1 - F12, Tab, Bksp, Enter,
  6497.                   Left, Right, Home, End, PgUp, PgDn, Ins, or Del
  6498.         Shift     followed by F1 - F12 or Tab.
  6499.  
  6500. The possible key names are: 
  6501.  
  6502.         A - Z     Enter     PgDn
  6503.         0 - 9     Up        Home
  6504.         F1 - F    Down      End
  6505.         Esc       Left      Ins
  6506.         Bksp      Right     Del
  6507.         Tab       PgUp
  6508.  
  6509. All key names must be spelled as shown.  Alphabetic keys can be specified in 
  6510. upper-case or lower-case.  You cannot specify a punctuation key. 
  6511.  
  6512. The prefix and key name must be separated by a dash [-]. For example: 
  6513.  
  6514.         Alt-F10   This is okay
  6515.         Alt F10   The space will cause an error
  6516.  
  6517. If you prefer, you can use a numeric value instead of a key name. Use the ASCII 
  6518. code for an ASCII, extended ASCII, or control character. Use the scan code 
  6519. preceded by an at sign [@] for extended key codes like F1 or the cursor keys. 
  6520. For example, use 13 for Enter, or @59 for F1.  In general, you will find it 
  6521. easier to use the names described above rather than key numbers. 
  6522.  
  6523. Some keys are intercepted by OS/2 and are not passed on to Take Command.  For 
  6524. example, Ctrl-S pauses screen output temporarily, and Alt-Tab switches to 
  6525. another window.  Keys which are intercepted by OS/2 generally cannot be 
  6526. assigned to aliases or with key mapping directives, because Take Command never 
  6527. receives these keystrokes and therefore cannot act on them. 
  6528.  
  6529. You also may not be able to use certain keys if your keyboard is not 100% 
  6530. IBM-compatible or your keyboard driver does not support them.  For example, on 
  6531. some systems the F11 and F12 keys are not recognized; others may not support 
  6532. unusual combinations like Ctrl-Tab.  These problems are rare; when they do 
  6533. occur, they are usually due to OS/2 and not to any problem with Take Command. 
  6534.  
  6535.  
  6536. ΓòÉΓòÉΓòÉ 4.2. The Command Line ΓòÉΓòÉΓòÉ
  6537.  
  6538. Take Command displays a [c:\] prompt when it is waiting for you to enter a 
  6539. command.  (The actual text depends on the current drive and directory as well 
  6540. as your PROMPT settings.)  This is called the command line and the prompt is 
  6541. asking you to enter a command, an alias or batch file name, or the instructions 
  6542. necessary to begin an application program. 
  6543.  
  6544. This section explains the features that will help you while you are typing in 
  6545. commands, how keystrokes are interpreted when you enter them at the command 
  6546. line, and how to transfer text between Take Command and other OS/2 
  6547. applications. 
  6548.  
  6549. The keystrokes discussed here are the ones normally used by Take Command.  If 
  6550. you prefer using different keystrokes to perform these functions, you can 
  6551. assign new ones with key mapping directives in the .INI file. 
  6552.  
  6553. The command line features documented in this section are: 
  6554.  
  6555.             Command-Line Editing 
  6556.             Command History and Recall 
  6557.             Command History Window 
  6558.             Filename Completion 
  6559.             Directory History Window 
  6560.             Automatic Directory Changes 
  6561.             Multiple Commands 
  6562.             Command-Line Length Limits 
  6563.             Page and File Prompts 
  6564.             Conditional Commands 
  6565.             Command Grouping 
  6566.             Escape Character 
  6567.             Critical Errors 
  6568.  
  6569.  Additional command-line features are documented under Redirection and Piping 
  6570.  and File Selection. 
  6571.  
  6572.  
  6573. ΓòÉΓòÉΓòÉ 4.2.1. Command-Line Editing ΓòÉΓòÉΓòÉ
  6574.  
  6575. The command line works like a single-line word processor, allowing you to edit 
  6576. any part of the command at any time before you press Enter to execute it, or 
  6577. Esc to erase it.  The command line extends to a maximum of 1023 characters. 
  6578.  
  6579. You can use the following editing keys when you are typing a command (the words 
  6580. Ctrl and Shift mean to press the Ctrl or Shift key together with the other key 
  6581. named): 
  6582.  
  6583. Cursor Movement Keys: 
  6584.  
  6585.                        Move the cursor left one character. 
  6586.                        Move the cursor right one character. 
  6587.         Ctrl           Move the cursor left one word. 
  6588.         Ctrl           Move the cursor right one word. 
  6589.         Home            Move the cursor to the beginning of the line. 
  6590.         End             Move the cursor to the end of the line. 
  6591.  
  6592.  Insert and Delete: 
  6593.  
  6594.         Ins             Toggle between insert and overtype mode. 
  6595.         Del             Delete the character at the cursor. 
  6596.         Backspace       Delete the character to the left of the cursor. 
  6597.         Ctrl-L          Delete the word or partial word to the left of the 
  6598.                         cursor. 
  6599.         Ctrl-R          or Ctrl-Bksp  Delete the word or partial word to the 
  6600.                         right of the cursor. 
  6601.         Ctrl-Home       Delete from the beginning of the line to the cursor. 
  6602.         Ctrl-End        Delete from the cursor to the end of the line. 
  6603.         Esc             Delete the entire line. 
  6604.         Ctrl-C          or Ctrl-Break  Cancel the command. 
  6605.         Enter           Execute the command line. 
  6606.  
  6607.  Take Command will prompt for additional command-line text when you include the 
  6608.  escape character as the very last character of a typed command line.  The 
  6609.  default escape character is the caret [^].  For example: 
  6610.  
  6611.           [c:\] echo The quick brown fox jumped over the lazy^
  6612.           More? sleeping dog. > alphabet
  6613.  
  6614.  Sometimes you may want to enter one of the above keystrokes on the command 
  6615.  line instead of performing the key's usual action.  For example, suppose you 
  6616.  have a program that requires a Ctrl-R character on its command line.  Normally 
  6617.  you couldn't type this keystroke at the prompt, because it would be 
  6618.  interpreted as a "Delete word right" command. 
  6619.  
  6620.  To get around this problem, use the special keystroke Alt-255. You enter 
  6621.  Alt-255 by holding down the Alt key while you type 255 on the numeric keypad, 
  6622.  then releasing the Alt key (you must use the number keys on the numeric pad; 
  6623.  the row of keys at the top of your keyboard won't work).  This forces Take 
  6624.  Command to interpret the next keystroke literally and places it on the command 
  6625.  line, ignoring any special meaning it would normally have as a command- line 
  6626.  editing or history keystroke.  You can use Alt-255 to suppress the normal 
  6627.  meaning of command-line editing keystrokes even if they have been reassigned 
  6628.  with key mapping directives in the .INI file, and Alt-255 itself can be 
  6629.  reassigned with the CommandEscape directive. 
  6630.  
  6631.  If you want your input at the command line to be in a different color from 
  6632.  Take Command's prompts or output, you can use the InputColors directive in 
  6633.  your .INI file. 
  6634.  
  6635.  Most of the command-line editing capabilities are also available when a Take 
  6636.  Command command prompts you for a line of input.  For example, you can use the 
  6637.  command-line editing keys when DESCRIBE prompts for a file description, when 
  6638.  INPUT prompts for input from an alias or batch file, or when LIST prompts you 
  6639.  for a search string. 
  6640.  
  6641.  
  6642. ΓòÉΓòÉΓòÉ 4.2.2. Command History and Recall ΓòÉΓòÉΓòÉ
  6643.  
  6644. Command History Keys: 
  6645.  
  6646.         Ctrl-          Recall the previous (or most recent) command, or the 
  6647.                         most recent command that matches a partial command 
  6648.                         line. 
  6649.         Ctrl-          Recall the next (or oldest) command, or the oldest 
  6650.                         command that matches a partial command line. 
  6651.         F3              Fill in the rest of the command line from the previous 
  6652.                         command, beginning at the current cursor position. 
  6653.         Ctrl-D          Delete the currently displayed history list entry, 
  6654.                         erase the command line, and display the previous 
  6655.                         matching history list entry. 
  6656.         Ctrl-E          Display the last entry in the history list. 
  6657.         Ctrl-K          Save the current command line in the history list 
  6658.                         without executing it, and then clear the command line. 
  6659.         Ctrl-Enter      Copy the current command line to the end of the history 
  6660.                         list even it has not been altered. 
  6661.         @               As the first character in a line:  Do not save the 
  6662.                         current line in the history list when it is executed, 
  6663.                         and do not store it in the CMDLINE environment 
  6664.                         variable. 
  6665.  
  6666.  Use the Ctrl- key repeatedly to scan back through the history list.  When the 
  6667.  desired command appears, press Enter to execute it again.  After you have 
  6668.  found a command, you can edit it before pressing Enter. 
  6669.  
  6670.  The history list is "circular".  If you move to the last command in the list 
  6671.  and then press the Ctrl- one more time, you'll see the first command in the 
  6672.  list.  Similarly, if you move to the first command in the list and then press 
  6673.  the Ctrl- one more time, you'll see the last command in the list. 
  6674.  
  6675.  You can search the command history list to find a previous command quickly 
  6676.  using command completion.  Just enter the first few characters of the command 
  6677.  you want to find and press Ctrl-. You only need to enter enough characters to 
  6678.  identify the command that you want to find.  If you press the Ctrl- key a 
  6679.  second time, you will see the previous command that matches.  The system will 
  6680.  beep if there are no matching commands.  The search process stops as soon as 
  6681.  you type one of the editing keys, whether or not the line is changed.  At that 
  6682.  point, the line you're viewing becomes the new line to match if you press 
  6683.  Ctrl- again. 
  6684.  
  6685.  You can specify the size of the command history list with the History 
  6686.  directive in the .INI file.  When the list is full, the oldest commands are 
  6687.  discarded to make room for new ones.  You can also use the HistMin directive 
  6688.  in the .INI file to enable or disable history saves and to specify the 
  6689.  shortest command line that will be saved. 
  6690.  
  6691.  You can prevent any command line from being saved in the history by beginning 
  6692.  it with an at sign [@]. 
  6693.  
  6694.  Use Ctrl-Enter to organize the history list for repetitive tasks.  Instead of 
  6695.  searching through the command history for the next command in a sequence, you 
  6696.  can place all of the necessary commands next to each other and make them 
  6697.  easier to repeat. 
  6698.  
  6699.  When you execute a command from the history, that command remains in the 
  6700.  history list in its original position.  The command is not copied to the end 
  6701.  of the list (unless you modify it).  If you want each command to be copied to 
  6702.  the end of the list when it is re-executed, set HistCopy to Yes in your .INI 
  6703.  file. 
  6704.  
  6705.  Local and Global Command History 
  6706.  
  6707.  The command history can be stored in either a "local" or "global" list. 
  6708.  
  6709.  With a local history list, any changes made to the history will only affect 
  6710.  the current copy of Take Command.  They will not be visible in other shells, 
  6711.  or other sessions. 
  6712.  
  6713.  With a global history list, all copies of Take Command will share the same 
  6714.  command history, and any changes made to the history in one copy will affect 
  6715.  all other copies.  Global lists are the default for Take Command. 
  6716.  
  6717.  You can control the type of history list with the LocalHistory directive in 
  6718.  the .INI file, and with the /L and /LH options of the START command. 
  6719.  
  6720.  If you select a global history list you can share the history among all copies 
  6721.  of Take Command running in any session.  When you close all Take Command 
  6722.  sessions, the memory for the global history list is released, and a new, empty 
  6723.  history list is created the next time you start Take Command. 
  6724.  
  6725.  If you want the command history to be retained in memory even when no Take 
  6726.  Command session is running, see the SHRALIAS command, which retains the global 
  6727.  alias, command history, and directory history lists. 
  6728.  
  6729.  SHRALIAS retains the history list in memory, but cannot preserve it when OS/2 
  6730.  itself is shut down.  To save the history list when restarting OS/2, you must 
  6731.  store it in a file and reload it after the system restarts.  For details on 
  6732.  how to do so, see the HISTORY command. 
  6733.  
  6734.  
  6735. ΓòÉΓòÉΓòÉ 4.2.3. Command History Window ΓòÉΓòÉΓòÉ
  6736.  
  6737. Command History Window Keys: 
  6738.  
  6739.         Ctrl-PgUp       (from the command line)  Open the command history 
  6740.                         window. 
  6741.          or Ctrl-PgDn 
  6742.                        Scroll the display up one line. 
  6743.                        Scroll the display down one line. 
  6744.                        Scroll the display left 4 columns. 
  6745.                        Scroll the display right 4 columns. 
  6746.         PgUp            Scroll the display up one page. 
  6747.         PgDn            Scroll the display down one page. 
  6748.         Ctrl-PgUp       (inside the window)  Scroll the text in the window to 
  6749.                         the left. 
  6750.         Ctrl-PgDn       (inside the window)  Scroll the text in the window to 
  6751.                         the right. 
  6752.          or End 
  6753.         Ctrl-D          Delete the selected line from the history list. 
  6754.         Enter           Execute the selected line. 
  6755.         Ctrl-Enter      Move the selected line to the command line for editing. 
  6756.          or Ctrl-Double Click 
  6757.  
  6758.  You can view the command history in a scrollable command history window, and 
  6759.  select the command to modify or re-execute from those displayed in the window. 
  6760.  To activate the command history window press Ctrl-PgUp or Ctrl-PgDn at the 
  6761.  command line.  A window will appear in the upper right corner of the screen, 
  6762.  with the command you most recently executed marked with a highlight. (If you 
  6763.  just finished re-executing a command from the history, then the next command 
  6764.  in sequence will be highlighted.) 
  6765.  
  6766.  Once you have selected a command in the history window, press Enter or 
  6767.  double-click with the mouse to execute it immediately.  Press Ctrl-Enter or 
  6768.  hold down the Ctrl key while you double-click with the mouse to move the line 
  6769.  to the prompt for editing (you cannot edit the line directly in the history 
  6770.  window). 
  6771.  
  6772.  You can bring up a "filtered" history window by typing some characters on the 
  6773.  command line, then pressing Ctrl-PgUp or Ctrl-PgDn.  Only those commands 
  6774.  matching the typed characters will be displayed in the window. 
  6775.  
  6776.  If you prefer to use the PgUp key to access the command history without having 
  6777.  to press Ctrl (as in 4OS2), see the SwapScrollKeys directive in TCMDOS2.INI, 
  6778.  or the corresponding option on the Command Line page of the configuration 
  6779.  dialogs.  SwapScrollKeys switches the keystroke mapping so that the  and PgUp 
  6780.  keys manipulate the command history, and Ctrl-, Ctrl-, Ctrl-PgUp, and 
  6781.  Ctrl-PgDn are used to control the scrollback buffer.  For more details see 
  6782.  Scrolling and History Keystrokes. 
  6783.  
  6784.  You can control the position and size of the history window with configuration 
  6785.  directives in TCMDOS2.INI, or the corresponding items on the Command Line page 
  6786.  of the configuration dialogs.  You can also change the keys used in the window 
  6787.  with key mapping directives in the .INI file. 
  6788.  
  6789.  
  6790. ΓòÉΓòÉΓòÉ 4.2.4. Scrolling and History Keystrokes ΓòÉΓòÉΓòÉ
  6791.  
  6792. In order to support the scrollback buffer, some Take Command keystrokes are 
  6793. different from what you may be used to in 4OS2. Take Command uses the up / down 
  6794. arrows and PgUp / PgDn to scroll the buffer, and the Ctrl-Up and Ctrl-Down 
  6795. arrow keys for the command history. If you prefer to reverse this arrangement 
  6796. and use the arrow and PgUp keys to access the command history without having to 
  6797. press Ctrl (as in 4OS2), see the SwapScrollKeys directive in TCMDOS2.INI, or 
  6798. the corresponding option on the Command Line page of the configuration dialogs. 
  6799. (SwapScrollKeys does not affect the use of F6 for the directory history). 
  6800.  
  6801. You can also change the way any individual key operates with the corresponding 
  6802. key mapping directive in TCMDOS2.INI.  The directives associated with the 
  6803. history and scrolling keys are: 
  6804.  
  6805.     NextHistory 
  6806.     PrevHistory 
  6807.     HistWinOpen 
  6808.     DirWinOpen 
  6809.     ScrollUp 
  6810.     ScrollDown 
  6811.     ScrollPgUp 
  6812.     ScrollPgDn 
  6813.  
  6814.  
  6815. ΓòÉΓòÉΓòÉ 4.2.5. Filename Completion ΓòÉΓòÉΓòÉ
  6816.  
  6817. Filename Completion Keys: 
  6818.  
  6819.         F8                  Get the previous matching filename. 
  6820.          or Shift-Tab 
  6821.         F9                  Get the next matching filename. 
  6822.          or Tab 
  6823.         Ctrl-Shift-Tab      Keep the current matching filename and display the 
  6824.                             next matching name immediately after the current 
  6825.                             one. 
  6826.  
  6827.  Filename completion can help you by filling in a complete file name on the 
  6828.  command line when you only remember part of the name.  For example, if you 
  6829.  know the name of a file begins AU but you can't remember the rest of the name, 
  6830.  type: 
  6831.  
  6832.           [c:\] copy au
  6833.  
  6834.  and then press the Tab key or F9 key.  Take Command will search the current 
  6835.  directory for filenames that begin AU and insert the first one onto the 
  6836.  command line in place of the AU that you typed. 
  6837.  
  6838.  If this is the file that you want, simply complete the command.  If Take 
  6839.  Command didn't find the file that you were looking for, press Tab or F9 again 
  6840.  to substitute the next filename that begins with AU.  When there are no more 
  6841.  filenames that match your pattern, the system will beep each time you press 
  6842.  Tab or F9. 
  6843.  
  6844.  If you go past the filename that you want, press Shift-Tab or F8 to back up 
  6845.  and return to the previous matching filename. After you back up to the first 
  6846.  filename, the system will beep each time you press Shift-Tab or F8. 
  6847.  
  6848.  If you want to enter more than one matching filename on the same command line, 
  6849.  press Ctrl-Shift-Tab when each desired name appears. This will keep that name 
  6850.  and place the next matching filename after it on the command line.  You can 
  6851.  then use Tab (or F9) and Shift-Tab (or F8) to move through the remaining 
  6852.  matching files. 
  6853.  
  6854.  The pattern you use for matching may contain any valid filename characters, as 
  6855.  well as wildcard characters and extended wildcards.  For example, you can copy 
  6856.  the first matching .TXT file by typing 
  6857.  
  6858.           [c:\] copy *.txt
  6859.  
  6860.  and then pressing Tab. 
  6861.  
  6862.  If you don't specify part of a filename before pressing Tab, the matching 
  6863.  pattern will be *..  If you type a filename without an extension, Take Command 
  6864.  will add "*.*" to the name.  It will also place a "*" after a partial 
  6865.  extension.  If you are typing a group of file names in an Include Lists, the 
  6866.  part of the include list at the cursor will be used as the pattern to match. 
  6867.  
  6868.  When filename completion is used at the start of the command line, it will 
  6869.  only match directories, executable files, and files with executable extensions 
  6870.  , since these are the only file names that it makes sense to use at the start 
  6871.  of a command.  If a directory is found, a "\" will be appended to it to enable 
  6872.  an automatic directory change. 
  6873.  
  6874.  Filename Completion Window 
  6875.  
  6876.  You can also view filenames in a scrollable filename completion window and 
  6877.  select the file you want to work with.  To activate the window, press F7 or 
  6878.  Ctrl-Tab at the command line. You will see a window in the upper-right corner 
  6879.  of the screen, with the names of files that match any partial filename you 
  6880.  have entered on the command line.  If you haven't yet entered a file name, the 
  6881.  window will contain the name of all files in the current directory. (Ctrl-Tab 
  6882.  will work only if your keyboard and keyboard driver support it.  If it does 
  6883.  not work on your system, use F7 instead.) 
  6884.  
  6885.  Filename Completion Window Keys: 
  6886.  
  6887.         F7                  (from the command line)  Open the filename 
  6888.                             completion window. 
  6889.          or Ctrl-Tab 
  6890.                            Scroll the display up one line. 
  6891.                            Scroll the display down one line. 
  6892.                            Scroll the display left 4 columns. 
  6893.                            Scroll the display right 4 columns. 
  6894.         PgUp                Scroll the display up one page. 
  6895.         PgDn                Scroll the display down one page. 
  6896.         Ctrl-PgUp           Go to the beginning of the filename list. 
  6897.          or Home 
  6898.         Ctrl-PgDn           Go to the end of the filename list. 
  6899.          or End 
  6900.         Enter               Insert the selected filename into the command line. 
  6901.  
  6902.  
  6903. ΓòÉΓòÉΓòÉ 4.2.6. Directory History Window ΓòÉΓòÉΓòÉ
  6904.  
  6905. Directory History Window Keys: 
  6906.  
  6907.         F6              Open the directory history window. 
  6908.                        Scroll the display up one line. 
  6909.                        Scroll the display down one line. 
  6910.                        Scroll the display left 4 columns. 
  6911.                        Scroll the display right 4 columns. 
  6912.         PgUp            Scroll the display up one page. 
  6913.         PgDn            Scroll the display down one page. 
  6914.         Ctrl-PgUp       Go to the beginning of the directory list. 
  6915.          or Home 
  6916.         Ctrl-PgDn       Go to the end of the directory list. 
  6917.          or End 
  6918.         Ctrl-D          Delete the selected line from the directory list. 
  6919.         Enter           Change to the selected drive and directory. 
  6920.         Ctrl-Enter      Move the selected line to the command line for editing. 
  6921.  
  6922.  Every time you change to a new directory or drive, the current directory is 
  6923.  recorded in an internal directory history.  The length of the directory 
  6924.  history is 256 bytes by default; as new entries are added, old entries are 
  6925.  deleted from the list.  Directory changes are recorded whether you make them 
  6926.  from the command line with the CD, CDD, PUSHD, or POPD commands, with an 
  6927.  automatic directory change, or by typing a new drive letter followed by a 
  6928.  colon. Directories are recorded whether you change from one to another at the 
  6929.  command line, from within a batch file, or from within an alias. In order to 
  6930.  conserve space, each directory name is recorded just once in the directory 
  6931.  history, even if you move into and out of that directory several times. 
  6932.  
  6933.  You can view the directory history from the scrollable directory history 
  6934.  window and change to any drive and directory on the list. To activate the 
  6935.  directory history window, press F6 at the command line.  You can then select a 
  6936.  new directory with the Enter key or by double-clicking with the mouse. 
  6937.  
  6938.  You can control the length of the directory history with initialization 
  6939.  directives and the size of the window with configuration directives in 
  6940.  TCMDOS2.INI.  You can also use the corresponding items on the Startup and 
  6941.  Command Line pages of the configuration notebook.  You can change the keys 
  6942.  used in the window with key mapping directives in the .INI file. 
  6943.  
  6944.  Local and Global Directory History 
  6945.  
  6946.  The directory history can be stored in either a local or global list.  A 
  6947.  global list is the default. 
  6948.  
  6949.  With a local directory history list, any changes made to the list will only 
  6950.  affect the current copy of Take Command.  They will not be visible in other 
  6951.  copies. 
  6952.  
  6953.  With a global list, all copies of Take Command running in the same session 
  6954.  will share the same directory history, and any changes made to the list in one 
  6955.  copy will affect all other copies. 
  6956.  
  6957.  You can control the type of directory history list with the LocalDirHistory 
  6958.  directive in TCMDOS2.INI and with the /L and /LD options of the START command. 
  6959.  
  6960.  There is no fixed rule for deciding whether to use a local or global directory 
  6961.  history list.  Depending on your work style, you may find it most convenient 
  6962.  to use one type, or a mixture of types in different sessions or shells.  We 
  6963.  recommend that you start with the default approach and then modify it if you 
  6964.  find a situation where the default is not convenient. 
  6965.  
  6966.  If you select a global directory history you can share the history among all 
  6967.  copies of Take Command running in any session.  When you close all Take 
  6968.  Command sessions, the memory for the global directory history is released, and 
  6969.  a new, empty directory history is created the next time you start Take 
  6970.  Command. 
  6971.  
  6972.  If you want the directory history to be retained in memory even when no Take 
  6973.  Command session is running, see the SHRALIAS command, which retains the global 
  6974.  alias, command history, and directory history lists. 
  6975.  
  6976.  SHRALIAS retains the directory history list in memory, but cannot preserve it 
  6977.  when OS/2 itself is shut down.  Take Command always starts with an empty 
  6978.  directory history after the system is restarted. 
  6979.  
  6980.  
  6981. ΓòÉΓòÉΓòÉ 4.2.7. Automatic Directory Changes ΓòÉΓòÉΓòÉ
  6982.  
  6983. The automatic directory change feature gives you a quick method for changing 
  6984. directories.  You can use an automatic directory change in place of the CD or 
  6985. CDD command.  To do so, simply type the name of the directory you want to 
  6986. change to at the prompt, with a backslash [\] at the end.  For example: 
  6987.  
  6988.         [c:\] tcmd\
  6989.         [c:\tcmd]
  6990.  
  6991. This feature can make directory changes very simple when it's combined with 
  6992. CDPATH, a list of directories for the CD and CDD commands to search if the 
  6993. directory you name does not exist below the current directory.  For example, 
  6994. suppose CDPATH is set to C:\;D:\;E:\, and the directory WIN exists on drive E:. 
  6995. You can change to this directory with a single word on the command line: 
  6996.  
  6997.         [c:\tcmd] win\
  6998.         [e:\win]
  6999.  
  7000. In executing the command shown above, Take Command first looks for a WIN 
  7001. subdirectory of the current directory, i.e., C:\Take Command\WIN.  If no such 
  7002. directory exists it looks for a WIN subdirectory in every directory in the 
  7003. CDPATH list, and changes to the first one it finds. 
  7004.  
  7005. Internally, automatic directory changes use the CDD command, so the text before 
  7006. the backslash can include a drive letter, a full path, or a partial path. 
  7007. Commands like "....\" can be used to move up the directory tree quickly (see 
  7008. Extended Parent Directory Names). Automatic directory changes save the current 
  7009. directory, so it can be recalled with a "CDD -" or "CD -" command. 
  7010.  
  7011.  
  7012. ΓòÉΓòÉΓòÉ 4.2.8. Multiple Commands ΓòÉΓòÉΓòÉ
  7013.  
  7014. You can type several commands on the same command line, separated by an 
  7015. ampersand [&].  For example, if you know you want to copy all of your .TXT 
  7016. files to drive A: and then run CHKDSK to be sure that drive A's file structure 
  7017. is in good shape, you could enter the following command: 
  7018.  
  7019.         [c:\] copy *.txt a: & chkdsk a:
  7020.  
  7021. You may put as many commands on the command line as you wish, as long as the 
  7022. total length of the command line does not exceed 1023 characters. 
  7023.  
  7024. You can use multiple commands in batch files and alias definitions as well as 
  7025. from the command line. 
  7026.  
  7027. If you don't like using the default command separator, you can pick another 
  7028. character using the SETDOS /C command or the CommandSep directive in the .INI 
  7029. file.  If you plan to share aliases or batch files between 4DOS, 4OS2, 4DOS/NT 
  7030. and Take Command, see 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility for 
  7031. details about choosing compatible command separators for two or more products. 
  7032.  
  7033.  
  7034. ΓòÉΓòÉΓòÉ 4.2.9. Command-Line Length Limits ΓòÉΓòÉΓòÉ
  7035.  
  7036. When you first enter a command at the prompt or in an alias or batch file, it 
  7037. can be up to 1,023 characters long. 
  7038.  
  7039. As Take Command scans the command line and substitutes the contents of aliases 
  7040. and environment variables for their names, the line usually gets longer.  This 
  7041. expanded line is stored in an internal buffer which allows each individual 
  7042. command to grow to 1,023 characters during the expansion process.  In addition, 
  7043. if you have multiple commands on a single line, during expansion the entire 
  7044. line can grow to as much as 2,047 characters. If your use of aliases or 
  7045. environment variables causes the command line to exceed either of these limits 
  7046. as it is expanded, you will see an error message and the remainder of the line 
  7047. will not be executed. 
  7048.  
  7049.  
  7050. ΓòÉΓòÉΓòÉ 4.2.10. Page and File Prompts ΓòÉΓòÉΓòÉ
  7051.  
  7052. Several Take Command commands can generate prompts, which wait for you to press 
  7053. a key to view a new page or to perform a file activity. 
  7054.  
  7055. When Take Command is displaying information in page mode, for example with a 
  7056. DIR /P or SET /P command, it displays the message 
  7057.  
  7058.         Press Esc to Quit or any other key to continue...
  7059.  
  7060. At this prompt, you can press Esc, Ctrl-C, or Ctrl- Break if you want to quit 
  7061. the command.  You can press almost any other key to continue with the command 
  7062. and see the next page of information. 
  7063.  
  7064. During file processing, if you have activated prompting with a command like DEL 
  7065. /P, you will see this prompt before processing every file: 
  7066.  
  7067.         Y/N/R ?
  7068.  
  7069. You can answer this prompt by pressing Y for "Yes, process this file;"  N for 
  7070. "No, do not process this file;" R for "process the Remainder of the files 
  7071. without further prompting; or Esc for "cancel further processing for this 
  7072. argument."  You can also press Ctrl-C or Ctrl-Break at this prompt to cancel 
  7073. the remainder of the command. 
  7074.  
  7075.  
  7076. ΓòÉΓòÉΓòÉ 4.2.11. Conditional Commands ΓòÉΓòÉΓòÉ
  7077.  
  7078. Conditional commands allow you to perform tasks based upon the previous 
  7079. command's exit code. Many programs return a 0 if they are successful and a 
  7080. non-zero value if they encounter an error. 
  7081.  
  7082. If you separate two commands by && (AND), the second command will be executed 
  7083. only if the first returns an exit code of 0. For example, the following command 
  7084. will only erase files if the BACKUP operation succeeds: 
  7085.  
  7086.         [c:\] backup c:\ a: && del c:\*.bak;*.lst
  7087.  
  7088. If you separate two commands by || (OR), the second command will be executed 
  7089. only if the first returns a non-zero exit code. For example, if the following 
  7090. BACKUP operation fails, then ECHO will display a message: 
  7091.  
  7092.         [c:\] backup c:\ a: || echo Error in the backup!
  7093.  
  7094. All internal commands return an exit code, but not all external programs do. 
  7095. Conditional commands will behave unpredictably if you use them with external 
  7096. programs which do not return an explicit exit code. 
  7097.  
  7098.  
  7099. ΓòÉΓòÉΓòÉ 4.2.12. Command Grouping ΓòÉΓòÉΓòÉ
  7100.  
  7101. Command grouping allows you to logically group a set of commands together by 
  7102. enclosing them in parentheses.  The parentheses are similar in function to the 
  7103. BEGIN and END block statements in some programming languages. 
  7104.  
  7105. There are two primary uses for command grouping.  One is to execute multiple 
  7106. commands in a place where normally only a single command is allowed.  For 
  7107. example, suppose you want to copy then rename all the .WKQ files on drives A: 
  7108. and B: using the FOR command.  You could do it like this: 
  7109.  
  7110.         [c:\] for %drv in (A B) do copy %drv:*.wkq d:\wksave\
  7111.         [c:\] for %drv in (A B) do ren %drv:*.wkq *.old
  7112.  
  7113. But with command grouping you can do the same thing in one command (enter this 
  7114. on one line): 
  7115.  
  7116.         [c:\] for %drv in (A B) do (copy %drv:*.wkq d:\wksave\ &
  7117. ren %drv:*.wkq *.sav)
  7118.  
  7119. The COPY and REN commands enclosed in the parentheses appear to FOR as if they 
  7120. were a single command, so both commands are executed for every element of the 
  7121. FOR list. 
  7122.  
  7123. You can also use command grouping to redirect input or output for several 
  7124. commands without repeatedly using the redirection symbols.  For example, 
  7125. consider the following batch file fragment which uses the ECHO command to 
  7126. create a file (with >), and to append to the file (with >>): 
  7127.  
  7128.         echo Data files %_date > filelist
  7129.         dir *.dat >> filelist
  7130.         echo. >> filelist
  7131.         echo Text files %_date >> filelist
  7132.         dir *.txt >> filelist
  7133.  
  7134. Using command grouping, these commands can be written much more simply.  Enter 
  7135. this example on one line: 
  7136.  
  7137.         (echo Data files %_date & dir *.dat & echo. & echo Text files
  7138. %_date & dir *.txt) > filelist
  7139.  
  7140. The redirection, which appears outside the parentheses, applies to all the 
  7141. commands within the parentheses.  Because the redirection is performed only 
  7142. once, the commands will run slightly faster than if each command was entered 
  7143. separately.  The same approach can be used for input redirection and for 
  7144. piping. 
  7145.  
  7146. You can also use command grouping in a batch file or at the prompt to split 
  7147. commands over several lines.  This last example is like the redirection example 
  7148. above, but is entered at the prompt.  Take Command displays a "More?" prompt 
  7149. after each incomplete line: 
  7150.  
  7151.         [c:\] (echo Data files %_date
  7152.         More? dir *.dat
  7153.         More? echo.
  7154.         More? echo Text files %_date
  7155.         More? dir *.txt) > filelist
  7156.         [c:\]
  7157.  
  7158. You cannot use the DO command in a command group. 
  7159.  
  7160.  
  7161. ΓòÉΓòÉΓòÉ 4.2.13. Escape Character ΓòÉΓòÉΓòÉ
  7162.  
  7163. Take Command recognizes a user-definable escape character.  This character 
  7164. gives the following character a special meaning; it is not the same as the 
  7165. ASCII ESC that is often used in ANSI and printer control sequences. 
  7166.  
  7167. The default escape character is a caret [^]. 
  7168.  
  7169. If you don't like using the default escape character, you can pick another 
  7170. character using the SETDOS /E command or the EscapeChar directive in your .INI 
  7171. file.  If you plan to share aliases or batch files between 4DOS, 4OS2, 4DOS/NT 
  7172. and Take Command, see 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility for 
  7173. details about choosing compatible escape characters for two or more products. 
  7174.  
  7175. Eight special characters are recognized when they are preceded by the escape 
  7176. character.  The combination of the escape character and one of these characters 
  7177. is translated to a single character, as shown below.  These are useful for 
  7178. redirecting codes to the printer, and ^r can be used in keystroke aliases.  The 
  7179. special characters which can follow the escape character are: 
  7180.  
  7181.         b   backspace 
  7182.         c   comma 
  7183.         e   the ASCII ESC character (ASCII 27) 
  7184.         f   form feed 
  7185.         n   line feed 
  7186.         r   carriage return 
  7187.         s   space 
  7188.         t   tab character 
  7189.  
  7190.  If you follow the escape character with any other character, the escape 
  7191.  character is removed and the second character is copied directly to the 
  7192.  command line.  This allows you to suppress the normal meaning of special 
  7193.  characters (such as ? * / \ | " ` > < and &). 
  7194.  
  7195.  For example, to send a form feed followed by the sequence ESC Y to the 
  7196.  printer, you can use this command: 
  7197.  
  7198.           [c:\] echos ^f^eY > prn
  7199.  
  7200.  
  7201. ΓòÉΓòÉΓòÉ 4.2.14. Critical Errors ΓòÉΓòÉΓòÉ
  7202.  
  7203. OS/2 watches for physical errors during input and output operations.  Physical 
  7204. errors are those due to hardware problems, such as trying to read a floppy disk 
  7205. while the drive door is open. 
  7206.  
  7207. These errors are called critical errors because OS/2, Take Command, or your 
  7208. application program cannot proceed until the error is resolved. 
  7209.  
  7210. When a critical error occurs, you will see a popup window asking you to choose 
  7211. an error handling option.  The message comes from OS/2, and will typically 
  7212. offer you three choices: 
  7213.  
  7214.         Return error code to program 
  7215.  
  7216.             Tell the program that the operation failed.  This option returns an 
  7217.             error code to Take Command or to the application program that was 
  7218.             running when the error occurred.  Take Command generally stops the 
  7219.             current command when an operation fails. 
  7220.  
  7221.         Retry command or operation 
  7222.  
  7223.             Choose this option if you have corrected the problem. 
  7224.  
  7225.         End program/command/operation 
  7226.  
  7227.             Terminate the program which generated the error.  Use this option 
  7228.             with caution as it is likely to close Take Command or any other 
  7229.             program which caused an error. 
  7230.  
  7231.  
  7232. ΓòÉΓòÉΓòÉ 4.3. Redirection and Piping ΓòÉΓòÉΓòÉ
  7233.  
  7234. This section covers redirection and piping.  You can use these features to 
  7235. change how Take Command and some application programs handle input and output. 
  7236.  
  7237. Internal commands and many external programs get their input from the 
  7238. computer's standard input device and send their output to the standard output 
  7239. device.  Some programs also send special messages to the standard error device. 
  7240. Normally, the keyboard is used for standard input and the video screen for both 
  7241. standard output and standard error.  Redirection and piping allow you to change 
  7242. these assignments temporarily. 
  7243.  
  7244. Redirection 
  7245.  
  7246. Redirection assigns standard input, standard output, and standard error to a 
  7247. device like the printer or serial port, or to a file. 
  7248.  
  7249. Redirection always applies to a specific command, and lasts only for the 
  7250. duration of that command.  When the command is finished, the assignments for 
  7251. standard input, standard output, and standard error revert to whatever they 
  7252. were before the command. 
  7253.  
  7254. Here are the standard redirection options supported by Take Command for OS/2 
  7255. (see below for additional redirection options using numeric file handles): 
  7256.  
  7257.         < filename          To get input from a file or device instead of from 
  7258.                             the keyboard 
  7259.         > filename          Redirect standard output to a file or device 
  7260.         >& filename         Redirect standard output and standard error to a 
  7261.                             file or device 
  7262.         >&> filename        Redirect standard error only to a file or device 
  7263.  
  7264.  To use redirection, place the redirection symbol and filename at the end of 
  7265.  the command line, after the command name and any parameters.  For example, to 
  7266.  redirect the output of the DIR command to a file called DIRLIST, you could use 
  7267.  a command line like this: 
  7268.  
  7269.           [c:\] dir /b *.dat > dirlist
  7270.  
  7271.  You can use both input and output redirection for the same command, if both 
  7272.  are appropriate: 
  7273.  
  7274.           [c:\] sort < dirlist > dirlist.srt
  7275.  
  7276.  If you redirect the output of a single internal command like DIR, the 
  7277.  redirection ends automatically when that command is done.  If you start a 
  7278.  batch file with redirection, all of the batch file's output is redirected, and 
  7279.  redirection ends when the batch file is done.  Similarly, if you use 
  7280.  redirection at the end of a command group, all of the output from the command 
  7281.  group is redirected, and redirection ends when the command group is done. 
  7282.  
  7283.  If you want to append output to the end of an existing file, rather than 
  7284.  creating a new file, replace the first ">" in the output redirection symbol 
  7285.  with ">>" (use >>, >>&, and >>&>). 
  7286.  
  7287.  When output is directed to a file with >, >&, or >&>, if the file already 
  7288.  exists, it will be overwritten.  You can protect existing files by using the 
  7289.  SETDOS /N1 command or the NoClobber directive in the .INI file. 
  7290.  
  7291.  When output is appended to a file with >>, >>&, or >>&>, the file will be 
  7292.  created if it doesn't already exist. Setting NoClobber will also prevent the 
  7293.  creation of a new file. 
  7294.  
  7295.  You can temporarily override the current setting of NoClobber by using an 
  7296.  exclamation mark [!] after the redirection symbol. For example, to redirect 
  7297.  the output of DIR to the file DIROUT, and allow overwriting of any existing 
  7298.  file despite the NoClobber setting: 
  7299.  
  7300.           [c:\] dir >! dirout
  7301.  
  7302.  Redirection is fully nestable.  For example, you can invoke a batch file and 
  7303.  redirect all of its output to a file or device.  Output redirection on a 
  7304.  command within the batch file will take effect for that command only; when the 
  7305.  command is completed, output will revert to the redirected output file or 
  7306.  device in use for the batch file as a whole. 
  7307.  
  7308.  You can use redirection if you need to create a zero-byte file.  To do so, 
  7309.  enter  >filename as a command, with no actual command before the > character. 
  7310.  
  7311.  In addition to the standard redirection options, Take Command also supports 
  7312.  the OS/2 CMD.EXE syntax: 
  7313.  
  7314.         n>file      Redirect handle n to the named file 
  7315.         n>&m        Redirect handle n to the same place as handle m 
  7316.  
  7317.  [n] and [m] are one-digit file handles between 0 and 9.  You may not put any 
  7318.  spaces between the n and the >, or between the >, &, and m in the second form. 
  7319.  OS/2 interprets "0" as standard input, "1" as standard output, and "2" as 
  7320.  standard error.  Handles 3 to 9 will probably not be useful unless you have an 
  7321.  application which uses those handles for a specific, documented purpose, or 
  7322.  have opened a file with the %@FILEOPEN variable function and the file handle 
  7323.  is between 3 and 9. 
  7324.  
  7325.  Piping 
  7326.  
  7327.  You can create a "pipe" to send the standard output of one command to the 
  7328.  standard input of another command: 
  7329.  
  7330.         command1 | command2             Send the standard output of command1 to 
  7331.                                         the standard input of command2 
  7332.         command1 |& command2            Send the standard output and standard 
  7333.                                         error of command1 to the standard input 
  7334.                                         of command2 
  7335.  
  7336.  For example, to take the output of the SET command (which displays a list of 
  7337.  your environment variables and their values) and pipe it to the SORT utility 
  7338.  to generate a sorted list, you would use the command: 
  7339.  
  7340.           [c:\] set | sort
  7341.  
  7342.  To do the same thing and then pipe the sorted list to the internal LIST 
  7343.  command for full-screen viewing: 
  7344.  
  7345.           [c:\] set | sort | list /s
  7346.  
  7347.  The TEE and Y commands are "pipe fittings" which add more flexibility to 
  7348.  pipes. 
  7349.  
  7350.  Like redirection, pipes are fully nestable.  For example, you can invoke a 
  7351.  batch file and send all of its output to another command with a pipe.  A pipe 
  7352.  on a command within the batch file will take effect for that command only; 
  7353.  when the command is completed, output will revert to the pipe in use for the 
  7354.  batch file as a whole. 
  7355.  
  7356.  Take Command implements pipes by starting a new process for the receiving 
  7357.  program instead of using temporary files.  The sending and receiving programs 
  7358.  run simultaneously; the sending program writes to the pipe and the receiving 
  7359.  program reads from the pipe.  When the receiving program finishes reading and 
  7360.  processing the piped data, it is ended automatically. 
  7361.  
  7362.  When you use pipes with Take Command make sure you think about any possible 
  7363.  consequences that can occur from using a separate process to run the receiving 
  7364.  program. 
  7365.  
  7366.  
  7367. ΓòÉΓòÉΓòÉ 4.4. File Selection ΓòÉΓòÉΓòÉ
  7368.  
  7369. Most internal commands (like COPY, DIR, etc.) work on a file or a group of 
  7370. files. Besides typing the exact name of the file you want to work with, you can 
  7371. use several shorthand forms for naming or selecting files. 
  7372.  
  7373. The features explained in this section apply to Take Command commands only, and 
  7374. generally can not be used to pass file names to external programs unless those 
  7375. programs were specifically written to support these features. 
  7376.  
  7377. The file selection features are: 
  7378.  
  7379.     Extended Parent Directory Names 
  7380.     Wildcards 
  7381.     Date, Time, and Size Ranges 
  7382.     Multiple Filenames 
  7383.     Include Lists 
  7384.     Executable Extensions 
  7385.  
  7386.  
  7387. ΓòÉΓòÉΓòÉ 4.4.1. Extended Parent Directory Names ΓòÉΓòÉΓòÉ
  7388.  
  7389. Take Command allows you to extend the traditional syntax for naming the parent 
  7390. directory, by adding additional [.] characters.  Each additional [.] represents 
  7391. an additional directory level above the current directory.  For example, 
  7392. .\FILE.DAT refers to a file in the current directory, ..\FILE.DAT refers to a 
  7393. file one level up (in the parent directory), and ...\FILE.DAT refers to a file 
  7394. two levels up (in the parent of the parent directory). If you are in the 
  7395. C:\DATA\FINANCE\JANUARY directory and want to copy the file LETTERS.DAT from 
  7396. the directory C:\DATA to drive A: 
  7397.  
  7398.         [C:\DATA\FINANCE\JANUARY] copy ...\LETTERS.DAT A:
  7399.  
  7400.  
  7401. ΓòÉΓòÉΓòÉ 4.4.2. Wildcards ΓòÉΓòÉΓòÉ
  7402.  
  7403. Wildcards let you specify a file or group of files by typing a partial 
  7404. filename.  The appropriate directory is scanned to find all of the files that 
  7405. match the partial name you have specified. 
  7406.  
  7407. There are two wildcard characters, the asterisk [*] and the question mark [?], 
  7408. plus a special method of specifying a range of permissible characters. 
  7409.  
  7410. An asterisk [*] in a filename means "any zero or more characters in this 
  7411. position."  For example, this command will display a list of all files in the 
  7412. current directory: 
  7413.  
  7414.         [c:\] dir *.*
  7415.  
  7416. If you want to see all of the files with a .TXT extension, you could type this: 
  7417.  
  7418.         [c:\] dir *.txt
  7419.  
  7420. If you know that the file you are looking for has a base name that begins with 
  7421. ST and an extension that begins with .D, you can find it this way. Filenames 
  7422. such as STATE.DAT, STEVEN.DOC, and ST.D will all be displayed: 
  7423.  
  7424.         [c:\] dir st*.d*
  7425.  
  7426. With Take Command, you can also use the asterisk to match filenames with 
  7427. specific letters somewhere inside the name.  The following example will display 
  7428. any file with a .TXT extension that has the letters AM together anywhere inside 
  7429. its base name.  It will, for example, display AMPLE.TXT, STAMP.TXT, CLAM.TXT, 
  7430. and AM.TXT: 
  7431.  
  7432.         [c:\] dir *am*.txt
  7433.  
  7434. A question mark [?] matches any single filename character. You can put the 
  7435. question mark anywhere in a filename and use as many question marks as you 
  7436. need.  The following example will display files with names like LETTER.DOC and 
  7437. LATTER.DAT, and LITTER.DU: 
  7438.  
  7439.         [c:\] dir l?tter.d??
  7440.  
  7441. The use of an asterisk wildcard before other characters, and of the character 
  7442. ranges discussed below, are enhancements to the standard wildcard syntax, and 
  7443. are not likely to work properly with software other than Take Command. 
  7444.  
  7445. "Extra" question marks in your wildcard specification are ignored if the file 
  7446. name is shorter than the wildcard specification.  For example, if you have 
  7447. files called LETTER.DOC, LETTER1.DOC, and LETTERA.DOC, this command will 
  7448. display all three names: 
  7449.  
  7450.         [c:\] dir letter?.doc
  7451.  
  7452. The file LETTER.DOC is included in the display because the "extra" question 
  7453. mark at the end of "LETTER?" is ignored when matching the shorter name LETTER. 
  7454.  
  7455. In some cases, the question mark wildcard may be too general.  You can also 
  7456. specify what characters you want to accept (or exclude) in a particular 
  7457. position in the filename by using square brackets. Inside the brackets, you can 
  7458. put the individual acceptable characters or ranges of characters. For example, 
  7459. if you wanted to match LETTER0.DOC through LETTER9.DOC, you could use this 
  7460. command: 
  7461.  
  7462.         [c:\] dir letter[0-9].doc
  7463.  
  7464. You could find all files that have a vowel as the second letter in their name 
  7465. this way.  This example also demonstrates how to mix the wildcard characters: 
  7466.  
  7467.         [c:\] dir ?[aeiouy]*.*
  7468.  
  7469. You can exclude a group of characters or a range of characters by using an 
  7470. exclamation mark [!] as the first character inside the brackets.  This example 
  7471. displays all filenames that are at least 2 characters long!except those which 
  7472. have a vowel as the second letter in their names: 
  7473.  
  7474.         [c:\] dir ?[!aeiouy]*.*
  7475.  
  7476. The next example, which selects files such as AIP, BIP, and TIP but not NIP, 
  7477. demonstrates how you can use multiple ranges inside the brackets.  It will 
  7478. accept a file that begins with an A, B, C, D, T, U, or V: 
  7479.  
  7480.         [c:\] dir [a-dt-v]ip
  7481.  
  7482. You may use a question mark character inside the brackets, but its meaning is 
  7483. slightly different than a normal (unbracketed) question mark wildcard.  A 
  7484. normal question mark wildcard matches any character, but will be ignored when 
  7485. matching a name shorter than the wildcard specification, as described above.  A 
  7486. question mark inside brackets will match any character, but will not be 
  7487. discarded when matching shorter filenames.  For example: 
  7488.  
  7489.         [c:\] dir letter[?].doc
  7490.  
  7491. will display LETTER1.DOC and LETTERA.DOC, but not LETTER.DOC.  A pair of 
  7492. brackets with no characters between them [], or an exclamation point and 
  7493. question mark together [!?],will match only if there is no character in that 
  7494. position.  For example, 
  7495.  
  7496.         [c:\] dir letter[].doc
  7497.  
  7498. will not display LETTER1.DOC or LETTERA.DOC, but will display LETTER.DOC.  This 
  7499. is most useful for commands like 
  7500.  
  7501.         [c:\] dir /I"[]" *.btm
  7502.  
  7503. which will display a list of all .BTM files which don't have a description. 
  7504.  
  7505. You can repeat any of the wildcard characters in any combination you desire 
  7506. within a single file name.  For example, the following command lists all files 
  7507. which have an A, B, or C as the third character, followed by zero or more 
  7508. additional characters, followed by a D, E, or F, followed optionally by some 
  7509. additional characters, and with an extension beginning with P or Q.  You 
  7510. probably won't need to do anything this complex, but we've included it to show 
  7511. you the flexibility of extended wildcards: 
  7512.  
  7513.         [c:\] dir ??[abc]*[def]*.[pq]*
  7514.  
  7515. You can also use the square bracket wildcard syntax to work around a conflict 
  7516. between HPFS filenames containing semicolons [;], and the use of a semicolon to 
  7517. indicate an include list . For example, if you have a file on an HPFS drive 
  7518. named C:\DATA\LETTER1;V2 and you enter this command: 
  7519.  
  7520.         [c:\] del \data\letter1;v2
  7521.  
  7522. you will not get the results you expect.  Instead of deleting the named file, 
  7523. Take Command will attempt to delete LETTER1 and then V2, because the semicolon 
  7524. indicates an include list.  However if you use square brackets around the 
  7525. semicolon it will be interpreted as a filename character, and not as an include 
  7526. list separator.  For example, this command would delete C:\DATA\LETTER1;V2: 
  7527.  
  7528.         [c:\] del \data\letter1[;]v2
  7529.  
  7530.  
  7531. ΓòÉΓòÉΓòÉ 4.4.3. Date, Time, and Size Ranges ΓòÉΓòÉΓòÉ
  7532.  
  7533. Most internal commands which accept wild cards also allow date, time, and size 
  7534. ranges to further define the files that you wish to work with.  Take Command 
  7535. will examine the files' time stamps (which record when the file was last 
  7536. modified), and the files' sizes, to determine which files meet the range 
  7537. criteria that you specify. 
  7538.  
  7539. A range begins with the switch character (/), followed by a left square bracket 
  7540. ("[") and a character that specifies the range type:  "s" for a size range, "d" 
  7541. for a date range, or "t" for a time range.  The "s", "d", or "t" is followed by 
  7542. a start value, and an optional comma and end value.  The range ends with a 
  7543. right square bracket ("]"). 
  7544.  
  7545. See the individual range types for details on specifying ranges: 
  7546.  
  7547.     Size Ranges 
  7548.     Date Ranges 
  7549.     Time Ranges 
  7550.  
  7551. Using Ranges 
  7552.  
  7553. If you combine two types of ranges, a file must satisfy both ranges to be 
  7554. included.  For example, /[d2-8-94,2-9-94] /[s1024,2048] means files last 
  7555. modified between February 8 and February 9, 1994, which are also between 1,024 
  7556. and 2,048 bytes long. 
  7557.  
  7558. When you use a date, time, or size range in a command, it should immediately 
  7559. follow the command name.  Unlike some command switches which apply to only part 
  7560. of the command line, the range usually applies to all file names specified for 
  7561. the command.  Any exceptions are noted in the descriptions of individual 
  7562. commands. 
  7563.  
  7564. For example, to get a directory of all the *.C files dated October 1, 1994, you 
  7565. could use this command: 
  7566.  
  7567.         [c:\] dir /[d10-1-94,+0] *.c
  7568.  
  7569. To delete all of the 0-byte files on your hard disk, you could use this 
  7570. command: 
  7571.  
  7572.         [c:\] del /[s0,0] *.* /s
  7573.  
  7574. And to copy all of the non-zero byte files that you changed yesterday or today 
  7575. to your floppy disk, you can use this command: 
  7576.  
  7577.         [c:\] copy /[d-1] /[s1] *.* a:
  7578.  
  7579. File systems which support long filenames maintain 3 sets of dates and times 
  7580. for each file: creation, last access, and last modification.  By default, date 
  7581. and time ranges work with the last modification time stamp. You can use the 
  7582. "last access" (a) or "created" (c) time stamp in a date or time range with the 
  7583. syntax: 
  7584.  
  7585.         /[da...]
  7586.     or  /[dc...]
  7587.     or  /[ta...]
  7588.     or  /[tc...]
  7589.  
  7590. For example, to select files that were last accessed yesterday or today : 
  7591.  
  7592.         /[da-1]
  7593.  
  7594. Date, time, and size ranges can be used with the ATTRIB, COPY, DEL, DESCRIBE, 
  7595. DIR, EXCEPT, FFIND, FOR, LIST, MOVE, RD, REN, SELECT, and TYPE commands. They 
  7596. cannot be used with filename completion or in filename arguments for variable 
  7597. functions. 
  7598.  
  7599.  
  7600. ΓòÉΓòÉΓòÉ 4.4.3.1. Size Ranges ΓòÉΓòÉΓòÉ
  7601.  
  7602. Size ranges simply select files whose size is between the limits given.  For 
  7603. example, /[s10000,20000] selects files between 10,000 and 20,000 bytes long. 
  7604.  
  7605. Either or both values in a size range can end with "k" to indicate thousands of 
  7606. bytes, "K" to indicate kilobytes (1,024 bytes), "m" to indicate millions of 
  7607. bytes, or "M" to indicate megabytes (1,048,576 bytes).  For example, the range 
  7608. above could be rewritten as /[s10k,20k]. 
  7609.  
  7610. All ranges are inclusive.  Both examples above will match files that are 
  7611. exactly 10,000 bytes and 20,000 bytes long, as well as all sizes in between. 
  7612.  
  7613. The second argument of a size range is optional.  If you use a single argument, 
  7614. like /[s10k], you will select files of that size or larger.  You can also 
  7615. precede the second argument with a plus sign [+]; when you do, it is added to 
  7616. the first value to determine the largest file size to include in the search. 
  7617. For example, /[s10k,+1k] selects files from 10,000 through 11,000 bytes in 
  7618. size. 
  7619.  
  7620. Some further examples of size ranges: 
  7621.  
  7622.         Specification    Selects Files
  7623.         /[s0,0]          of length zero(empty)
  7624.         /[s1M]           1 megabyte or more in length
  7625.         /[s10k,+200]     between 10,000 and 10,200 bytes
  7626.  
  7627.  
  7628. ΓòÉΓòÉΓòÉ 4.4.3.2. Date Ranges ΓòÉΓòÉΓòÉ
  7629.  
  7630. Date ranges select files that were created or last modified at any time between 
  7631. the two dates.  For example, /[d12-1-94,12-5-94] selects files that were last 
  7632. modified between December 1, 1994, and December 5, 1994. 
  7633.  
  7634. The time for the starting date defaults to 00:00:00 and the time for the ending 
  7635. date defaults to 23:59:59.  You can alter these defaults, if you wish, by 
  7636. including a start and stop time inside the date range.  The time is separated 
  7637. from the date with an at sign [@].  For example, the range 
  7638. /[d7-1-94@8:00a,7-3-94@6:00p] selects files that were modified at any time 
  7639. between 8:00 am on July 1, 1994 and 6:00 PM on July 3, 1994.  If you prefer, 
  7640. you can specify the times in 24-hour format (e.g., @18:00 for the end time in 
  7641. the previous example).  The date format and the separator character used in the 
  7642. time may vary depending upon your country information. 
  7643.  
  7644. If you omit the second argument in a date range, Take Command substitutes the 
  7645. current date and time.  For example, /[d10-1-94] selects files dated between 
  7646. October 1, 1994 and today. 
  7647.  
  7648. You can use an offset value for either the beginning or ending date, or both. 
  7649. An offset begins with a plus sign [+] or a minus sign [-] followed by an 
  7650. integer.  If you use an offset for the second value, it is calculated relative 
  7651. to the first.  If you use an offset for the first (or only) value, the current 
  7652. date is used as the basis for calculation.  For example: 
  7653.  
  7654.         Specification     Selects Files
  7655.         /[d10-27-94,+3]   modified between 10-27-94 and 10-30-94
  7656.         /[d10-27-94,-3]   modified between 10-24-94 and 10-27-94
  7657.         /[d-0]            modified today (from today minus zero days,
  7658.                           to today)
  7659.         /[d-1]            modified yesterday or today (from today
  7660.                           minus one day, to today)
  7661.         /[d-1,+0]         modified yesterday (from today minus one
  7662.                           day, to zero days after that)
  7663.  
  7664. You cannot use offsets in the time portion of a date range (the part after an 
  7665. at sign), but you can combine a time with a date offset.  For example, 
  7666. /[d12-8-94@12:00,+2@12:00] selects files that were last modified between noon 
  7667. on December 8 and noon on December 10, 1994. Similarly, /[d-2@15:00,+1] selects 
  7668. files last modified between 3:00 PM the day before yesterday and the end of the 
  7669. day one day after that, i.e., yesterday.  The second time defaults to the end 
  7670. of the day because no time is given. 
  7671.  
  7672. OS/2 HPFS partitions keep track of the date a file was created, the date it was 
  7673. last modified (written), and the date it was last accessed.  You can specify 
  7674. which date and time is used in a date range by adding a (access), c (creation), 
  7675. or w (write) after the d in the range.  For example, to select all files 
  7676. created between February 1, 1994 and February 7, 1994 you would use 
  7677. /[dc2-1-94,2-7-94]. If you don't specify which date and time to use, Take 
  7678. Command will use the date the file was last modified (written). 
  7679.  
  7680.  
  7681. ΓòÉΓòÉΓòÉ 4.4.3.3. Time Ranges ΓòÉΓòÉΓòÉ
  7682.  
  7683. A time range specifies a file modification time without reference to the date. 
  7684. For example, to select files modified between noon and 2:00 PM on any date, use 
  7685. /[t12:00p,2:00p].  The times in a time range can either be in 12-hour format, 
  7686. with a trailing "a" for AM or "p" for PM, or in 24-hour format. 
  7687.  
  7688. If you omit the second argument in a time range, you will select files that 
  7689. were modified between the first time and the current time, on any date. You can 
  7690. also use offsets, beginning with a plus sign [+] or a minus sign [-] for either 
  7691. or both of the arguments in a time range.  The offset values are interpreted as 
  7692. minutes.  Some examples: 
  7693.  
  7694.         Specification      Selects Files
  7695.         /[t12:00p,+120]    modified between noon and 2:00
  7696.                            PM on any date
  7697.         /[t-120,+120]      modified between two hours ago and the
  7698.                            current time on any date
  7699.         /[t0:00,11:59]     modified in the morning on any date
  7700.  
  7701. The separator character used in the time may vary depending upon your country 
  7702. information. 
  7703.  
  7704.  
  7705. ΓòÉΓòÉΓòÉ 4.4.4. Multiple Filenames ΓòÉΓòÉΓòÉ
  7706.  
  7707. Most file processing commands can work with multiple files at one time.  To use 
  7708. multiple file names, you simply list the files one after another on the command 
  7709. line, separated by spaces.  You can use wildcards in any or all of the 
  7710. filenames.  For example, to copy all .TXT and .DOC files from the current 
  7711. directory to drive A, you could use this command: 
  7712.  
  7713.         [c:\] copy *.txt *.doc a:
  7714.  
  7715. If the files you want to work with are not in the default directory, you must 
  7716. include the full path with each filename: 
  7717.  
  7718.         [c:\] copy a:\details\file1.txt a:\details\file1.doc c:
  7719.  
  7720. Multiple filenames are handy when you want to match a group of files which 
  7721. cannot be defined with a single filename and wildcards.  They let you be very 
  7722. specific about which files you want to work with in a command. 
  7723.  
  7724. When you use multiple filenames with a command that expects both a source and a 
  7725. destination, like COPY or MOVE, be sure that you always include a specific 
  7726. destination on the command line.  If you don't, the command will assume that 
  7727. the last filename is the destination and may overwrite important files. 
  7728.  
  7729. Like extended wildcards and include lists, the multiple filename feature will 
  7730. work with internal commands but not with external programs, unless those 
  7731. programs have been written to handle multiple file names on the command line. 
  7732.  
  7733. If you have a list of files to process that's too long to put on the command 
  7734. line or too time-consuming to type, see the SELECT command for another way of 
  7735. passing multiple file names to a command. 
  7736.  
  7737.  
  7738. ΓòÉΓòÉΓòÉ 4.4.5. Include Lists ΓòÉΓòÉΓòÉ
  7739.  
  7740. Any internal command that accepts multiple filenames will also accept one or 
  7741. more include lists.  An include list is simply a group of filenames, with or 
  7742. without wildcards, separated by semicolons [;].  All files in the include list 
  7743. must be in the same directory.  You may not add a space on either side of the 
  7744. semicolon. 
  7745.  
  7746. For example, you can shorten this command which uses multiple file names: 
  7747.  
  7748.         [c:\] copy a:\details\file1.txt a:\details\file1.doc c:
  7749.  
  7750. to this using an include list: 
  7751.  
  7752.         [c:\] copy a:\details\file1.txt;file1.doc c:
  7753.  
  7754. Multiple filenames and include lists are processed differently by the DIR and 
  7755. SELECT commands. If you use multiple filenames, all of the files matching the 
  7756. first filename are processed, then all of the files matching the second name, 
  7757. and so on.  When you use an include list, all files that match any entry in the 
  7758. include list are processed together, and will appear together in the directory 
  7759. display or SELECT list.  You can see this difference clearly if you experiment 
  7760. with both techniques and the DIR command.  For example, 
  7761.  
  7762.         [c:\] dir *.txt *.doc
  7763.  
  7764. will list all the .TXT files with a directory header, the file list, and a 
  7765. summary of the total number of files and bytes used. Then it will do the same 
  7766. for the .DOC files.  However, 
  7767.  
  7768.         [c:\] dir *.txt;*.doc
  7769.  
  7770. will display all the files in one list. 
  7771.  
  7772. Like extended wildcards and multiple filenames, the include list feature will 
  7773. work with internal commands, but not with external programs (unless they have 
  7774. been programmed especially to support it). 
  7775.  
  7776.  
  7777. ΓòÉΓòÉΓòÉ 4.4.6. Executable Extensions ΓòÉΓòÉΓòÉ
  7778.  
  7779. Normally, when you type a filename (as opposed to an alias or internal command 
  7780. name) as the first word on the command line, Take Command looks for a file with 
  7781. that name to execute.  The file's extension may be .EXE or .COM to indicate 
  7782. that it contains a program, it may have a batch file extension like .BTM, or 
  7783. the file's contents may indicate that it is executable. 
  7784.  
  7785. You can add to this default list of extensions, and have Take Command take the 
  7786. action you want with files that are not executable programs or batch files. 
  7787. The action taken is always based on the file's extension. For example, you 
  7788. could start your text editor whenever you type the name of a .DOC file, or 
  7789. start your database manager whenever you type the name of a .DAT file. 
  7790.  
  7791. You can use environment variables to define the internal command, external 
  7792. program, batch file, or alias to run for each defined file extension.  To 
  7793. create an executable extension use the SET command to create a new environment 
  7794. variable.  An environment variable is recognized as an executable extension if 
  7795. its name begins with a period. 
  7796.  
  7797. The syntax for creating an executable extension is: 
  7798.  
  7799.         set .ext=command [options]
  7800.  
  7801. This tells Take Command to run the specified command whenever you name a file 
  7802. with the extension .ext at the prompt.  .EXT is the executable file extension; 
  7803. command is the name of the internal command, external program, alias, or batch 
  7804. file to run; and [options] are any command-line startup options you want to 
  7805. specify for the program, batch file, or alias. 
  7806.  
  7807. For example, if you want to run a word processor called EDITOR whenever you 
  7808. type the name of a file that has an extension of .EDT, you could use this 
  7809. command: 
  7810.  
  7811.         [c:\] set .edt=c:\edit\editor.exe
  7812.  
  7813. If the command specified in an executable extension is a batch file or external 
  7814. program, Take Command will search the PATH for it if necessary. However, you 
  7815. can make sure that the correct program or batch file is used, and speed up the 
  7816. executable extension, by specifying the full name including drive, path, 
  7817. filename, and extension. 
  7818.  
  7819. To remove an executable extension, use the UNSET command to remove the 
  7820. corresponding variable. 
  7821.  
  7822. Once an executable extension is defined, any time you name a file with that 
  7823. extension the corresponding program, batch file, or alias is started, with the 
  7824. name of your file passed to it as a parameter. 
  7825.  
  7826. This example defines B.EXE (the Boxer text editor) as the processor for .C 
  7827. files: 
  7828.  
  7829.         [c:\] set .c=c:\boxer\b.exe -Mxyz
  7830.  
  7831. Now, if you have a file called HELLO.C and enter the command 
  7832.  
  7833.         [c:\] hello -i30
  7834.  
  7835. This will be expanded to: 
  7836.  
  7837.         c:\brief\b.exe -Mxyz hello.c -i30
  7838.  
  7839. Notice that the text from the .C environment variable is inserted at the 
  7840. beginning of the line, including any options, followed by the original file 
  7841. name plus its extension, and then the remainder of the original command line. 
  7842.  
  7843. In order for executable extensions to work, the command, program, batch file, 
  7844. or alias must be able to interpret the command line properly.  For example, if 
  7845. a program you want to run doesn't accept a file name on its command line as 
  7846. shown in these examples, then executable extensions won't work with that 
  7847. program. 
  7848.  
  7849. Executable extensions may include wildcards, so you could, for example, run 
  7850. your text editor for any file with an extension beginning with T by defining an 
  7851. executable extension called .T*.  Extended wildcards (e.g., DO[CT] for .DOC and 
  7852. .DOT files) may also be used. 
  7853.  
  7854.  
  7855. ΓòÉΓòÉΓòÉ 4.5. Using an OS/2 "Graphical" Command Line ΓòÉΓòÉΓòÉ
  7856.  
  7857. Take Command for OS/2 is a new environment that lets you perform tasks easily 
  7858. under OS/2. You can use it to execute commands, start applications, and perform 
  7859. other work at the command line. 
  7860.  
  7861. In the past you may have accomplished some of these tasks by starting an OS/2 
  7862. character-mode session to run 4OS2, JP Software's replacement character-mode 
  7863. command processor. 
  7864.  
  7865. In either case -- and especially if you are an experienced user of 4OS2 -- 
  7866. you'll find plenty of familiar features in Take Command.  You'll also find a 
  7867. lot that's new and different. 
  7868.  
  7869. While Take Command includes most of the command-line, batch file, and other 
  7870. capabilities provided by 4OS2, and goes well beyond those provided by CMD.EXE, 
  7871. the OS/2 environment places a few limitations on how Take Command operates. 
  7872.  
  7873. These limitations are minor -- for example, some keystrokes are interpreted 
  7874. differently to conform more closely to OS/2 conventions, and there are some 
  7875. considerations when running batch files or OS/2 aliases designed to work in 
  7876. character mode under a graphical program like Take Command.  All of these 
  7877. differences are covered in more detail under Take Command for 4DOS, 4OS2 and 
  7878. 4DOS/NT Users. 
  7879.  
  7880. Take Command also offers a wide range of new OS/2 PM-related features which are 
  7881. not available in 4OS2 or CMD.EXE, including: 
  7882.  
  7883.         *   A built-in scrollback buffer that lets you look back through the 
  7884.             output from past commands. 
  7885.  
  7886.         *   A standard OS/2 menu bar for access to many commonly-used Take 
  7887.             Command features. 
  7888.  
  7889.         *   A status bar showing memory and resource usage. 
  7890.  
  7891.         *   A customizable tool bar that gives you quick access to commands and 
  7892.             applications. 
  7893.  
  7894.         *   Dialogs (accessible from the Options and Utilities menus) for 
  7895.             editing environment variables, aliases, file descriptions, and 
  7896.             startup parameters. 
  7897.  
  7898.         *   High-speed, dialog-based file and text search (see "Search 
  7899.             Files/Text" on the Utilities menu).  The new FFIND command gives 
  7900.             you the same capabilities at the Take Command prompt. 
  7901.  
  7902.         *   Commands like ACTIVATE, MSGBOX, and QUERYBOX that allow you to use 
  7903.             OS/2 features and control OS/2 applications from your batch files. 
  7904.  
  7905.  
  7906. ΓòÉΓòÉΓòÉ 4.6. Starting Applications ΓòÉΓòÉΓòÉ
  7907.  
  7908. Take Command offers several ways to start applications.  (For special 
  7909. considerations related to starting character-mode applications, see the next 
  7910. topic). 
  7911.  
  7912. First, you can simply type the name of any OS/2, DOS, or Windows application at 
  7913. the Take Command prompt.  As long as the application's executable file is in 
  7914. one of the standard search directories (see below), Take Command will find it 
  7915. and start it.  If you type the full path name of the executable file at the 
  7916. prompt the application will be started even if it is not in one of the standard 
  7917. search directories. 
  7918.  
  7919. Take Command offers two methods to simplify and speed up access to your 
  7920. applications.  One is to create an alias, for example: 
  7921.  
  7922.         [c:\] alias myapp d:\apps\myapp.exe
  7923.  
  7924. You can also use the Tool Bar to start frequently-used applications.  For 
  7925. example, a tool bar button named MyApp which invokes the command 
  7926. d:\apps\myapp.exe would accomplish the same thing as the alias shown above. 
  7927.  
  7928. You can use these methods together.  For example, if you define the alias shown 
  7929. above you can set up a tool bar button called MyApp and simply use the command 
  7930. myapp, which would then invoke the previously-defined alias. 
  7931.  
  7932. You can also start an application by typing the name of a data file associated 
  7933. with the application.  Take Command will examine the file's extension and run 
  7934. the appropriate application, based on Take Command's executable extensions. 
  7935.  
  7936. For additional flexibility, you can also start applications with the START 
  7937. command.  START provides a number of switches to customize the way an 
  7938. application is started. 
  7939.  
  7940. Searching for Applications 
  7941.  
  7942. When you start an application without specifying a path, Take Command searches 
  7943. for the application in the current directory and then all directories on the 
  7944. PATH.  (If you do enter an explicit path, Take Command will only look in the 
  7945. directory you specified.) 
  7946.  
  7947. If you enter a file name with no extension, Take Command will search each 
  7948. directory for a matching .COM, .EXE, .BTM, or .CMD file, then for a file 
  7949. matching a Take Command executable extension.  If no such file is found Take 
  7950. Command will move on to the next directory in the search sequence. 
  7951.  
  7952. Waiting for Applications to Finish 
  7953.  
  7954. When you start an application from the prompt, normally Take Command does not 
  7955. wait for the application to finish before returning to the prompt.  This allows 
  7956. you to continue your work in Take Command while the application is running. 
  7957. You can change this default behavior for applications started from the prompt, 
  7958. using the ExecWait directive in TCMDOS2.INI, or the External Programs option on 
  7959. the Options 2 page of the configuration notebook.  These options do not affect 
  7960. batch files; Take Command always waits for applications started from batch 
  7961. files. 
  7962.  
  7963. Character-mode applications which run inside the Take Command window are an 
  7964. exception to this rule.  Take Command always waits for such applications to 
  7965. finish before displaying a new prompt, regardless of the ExecWait setting. For 
  7966. more information see the next section, on starting character-mode applications. 
  7967.  
  7968. You can also force Take Command to wait for an application to finish with the 
  7969. START command with the /WAIT switch.  START can also control many other aspects 
  7970. of how your applications are started. 
  7971.  
  7972.  
  7973. ΓòÉΓòÉΓòÉ 4.6.1. Starting Character-Mode Applications ΓòÉΓòÉΓòÉ
  7974.  
  7975. Take Command for OS/2 starts OS/2 "graphical" applications in their own 
  7976. windows, just as if you had started them from the desktop.  By default, it also 
  7977. creates a separate character-mode window to run each DOS or OS/2 character mode 
  7978. application you start. 
  7979.  
  7980. If you prefer, you can run some DOS and OS/2 character-mode applications within 
  7981. the Take Command window, using an OS/2 facility called "named pipes."  When you 
  7982. use this option, output from the application is displayed in the Take Command 
  7983. window, and no separate window is created. 
  7984.  
  7985. Because not all applications work properly with named pipes, you must specify 
  7986. which TTY applications should be run within the Take Command window.  To do so, 
  7987. use the TTY Apps Dialog (accessible from the Setup menu).  The dialog lets you 
  7988. specify the application name, whether the application is a DOS or OS/2 
  7989. character-mode program, and whether or not the application is currently enabled 
  7990. to run within the Take Command window.  See the section on the TTY Applications 
  7991. dialog for details of the dialog fields and their meanings.  Information 
  7992. entered in this dialog is stored in the [TTYApps] section of TCMDOS2.INI. 
  7993.  
  7994. Once an application is listed in the dialog and enabled, it will run within the 
  7995. Take Command window whenever you start it from the command line.  However, if 
  7996. you start the application with the START command (without the /TTY switch, see 
  7997. below), the program will start in its own window.  The program will also start 
  7998. in its own window if you start it as the sending or receiving process in a pipe 
  7999. (see Redirection and Piping for details on pipes). 
  8000.  
  8001. Your copy of Take Command comes with a list of applications which can be run 
  8002. within the Take Command window.  The list is visible when you open the dialog, 
  8003. and is also included in the README.DOC file.  However, all applications in the 
  8004. list are initially disabled to ensure maximum compatibility.  This prevents 
  8005. problems if you have a program with the same name as one we tested, but which 
  8006. is not the same program or the same version.  To enable any application, select 
  8007. it and check the Enable box. 
  8008.  
  8009. You can explicitly start any character-mode application within the Take Command 
  8010. window by using the START command's /TTY switch.  For example: 
  8011.  
  8012.      start /tty c:\os2\chkdsk.com
  8013.  
  8014. Using this switch is the same as entering the application in the TTY 
  8015. Applications dialog and enabling it.  Using START /TTY is a convenient way to 
  8016. experiment with your DOS and OS/2 character-mode applications to see if they 
  8017. are compatible with Take Command's TTY application support. See the START 
  8018. command in the online help or Reference Manual for additional details. 
  8019.  
  8020. The only character-mode programs which will run properly within the Take 
  8021. Command window are those which can handle input and output delivered through 
  8022. pipes.  In technical terms, these are programs which read all input from the 
  8023. DOS or OS/2 "standard input" device, and write output to the "standard output" 
  8024. or "standard error" device.  Applications which use command-line parameters 
  8025. (rather than user input or "question and answer" dialogs), and which use simple 
  8026. scrolling (TTY-style) output, are the ones most likely to work well.  Common 
  8027. applications which run successfully in the Take Command window include program 
  8028. development software like compilers and linkers, and some command-line 
  8029. utilities. Programs which use "direct video" output to write complex screen 
  8030. displays, require dialog with the user, or display graphics, must be run in 
  8031. their own window. 
  8032.  
  8033. Many OS/2 character-mode programs meet this test, as do some DOS programs. 
  8034. However, some programs -- especially DOS programs -- which appear to work this 
  8035. way may in fact use internal tricks or contain internal restrictions which are 
  8036. not compatible with piped input and output. 
  8037.  
  8038. For this reason, you will need to experiment to determine which of your DOS and 
  8039. OS/2 character-mode applications can run successfully within the Take Command 
  8040. window.  If you try an application and it does not work, first try using Ctrl-C 
  8041. or Ctrl-Break to interrupt the application.  If this does not work you can 
  8042. close the Take Command window with the mouse to clean up the offending 
  8043. application, then restart Take Command from your desktop.  Applications which 
  8044. do not run properly within the Take Command window can still be run from Take 
  8045. Command, but will have to use their own window. 
  8046.  
  8047. TTY application support for DOS programs depends on the TCNPDOS.COM file 
  8048. distributed with Take Command.  This file must be available in the same 
  8049. directory as TCMDOS2.EXE.  If it is not, Take Command will display an error 
  8050. message if you try to run a DOS application within the Take Command window. 
  8051.  
  8052.  
  8053. ΓòÉΓòÉΓòÉ 4.7. Take Command for 4DOS and 4OS2 Users ΓòÉΓòÉΓòÉ
  8054.  
  8055. If you're a 4DOS or 4OS2 user, many of the features in Take Command will seem 
  8056. very familiar.  Because the underlying command processing in Take Command is 
  8057. based on 4DOS and 4OS2, you'll find the features of those products are readily 
  8058. accessible.  All the commands and switches you're familiar with work the same 
  8059. way and have the same meaning in Take Command; the only exceptions are those 
  8060. that don't make sense in the OS/2 GUI environment. 
  8061.  
  8062. Other 4DOS and 4OS2 features are included in Take Command as well -- you'll 
  8063. find support for command line editing, command and directory histories, 
  8064. aliases, .BTM files, and virtually all the other features you already know. 
  8065.  
  8066. Even if you've never used 4DOS or 4OS2, you'll notice plenty of familiar items 
  8067. in Take Command.  Like these products, Take Command is compatible with the 
  8068. default OS/2 command processor (CMD.EXE). 
  8069.  
  8070. There are also a few differences between running under 4DOS and 4OS2 (or 
  8071. CMD.EXE) and running under Take Command. 
  8072.  
  8073. In order to support the Take Command screen scrollback buffer, some Take 
  8074. Command keystrokes are different from what you may be used to in 4DOS or 4OS2. 
  8075. See Scrolling and History Keystrokes for more details. 
  8076.  
  8077. Some command-line editing defaults have also been changed to conform more 
  8078. closely to OS/2 GUI conventions. In Take Command the default editing mode is 
  8079. insert, not overstrike, and the default insert-mode cursor is a line, not a 
  8080. block.  You can change these defaults with statements in TCMDOS2.INI or via the 
  8081. Command Line page of the configuration notebook, accessible from the Setup 
  8082. menu. Before using your 4DOS or 4OS2 batch files and aliases under Take 
  8083. Command, see Using 4OS2 Batch Files and Aliases . 
  8084.  
  8085. What's new in Take Command are OS/2 GUI-related features, including: 
  8086.  
  8087.         *   A built-in scrollback buffer that lets you look back through the 
  8088.             output from past commands. 
  8089.  
  8090.         *   A standard menu bar for access to many commonly-used Take Command 
  8091.             features. 
  8092.  
  8093.         *   A status bar showing memory and resource usage. 
  8094.  
  8095.         *   A customizable tool bar that gives you quick access to commands and 
  8096.             applications. 
  8097.  
  8098.         *   Dialogs, accessible from the Options and Utilities menus, for 
  8099.             editing environment variables, aliases, file descriptions, and 
  8100.             startup parameters (the TCMDOS2.INI file). 
  8101.  
  8102.         *   High-speed, dialog-based file and text search (see "Search 
  8103.             Files/Text" on the Utilities menu).  The new FFIND command gives 
  8104.             you the same capabilities at the Take Command prompt. 
  8105.  
  8106.         *   Commands like ACTIVATE, MSGBOX, and QUERYBOX that allow you to use 
  8107.             OS/2 features and control OS/2 applications from your batch files. 
  8108.  
  8109.  
  8110. ΓòÉΓòÉΓòÉ 4.8. Using 4OS2 Batch Files and Aliases ΓòÉΓòÉΓòÉ
  8111.  
  8112. Take Command and 4OS2 aliases are separate and independent; Take Command does 
  8113. not automatically "inherit" aliases from a previously loaded copy of 4OS2, and 
  8114. it cannot pass aliases on to a copy of 4OS2 started from the Take Command 
  8115. prompt.  However, you can load aliases from your Take Command startup batch 
  8116. file.  These can be the same aliases you use in 4OS2, or a set that is just for 
  8117. Take Command. 
  8118.  
  8119. While many of your 4OS2 aliases will work well under Take Command, you'll 
  8120. probably want to create a separate set of Take Command aliases.  This will 
  8121. allow you to account for the differences in running character mode and PM 
  8122. applications, and to create new aliases that take advantage of Take Command 
  8123. features that are unavailable in 4OS2. 
  8124.  
  8125. If you want to write aliases or batch files that are used in both Take Command 
  8126. and 4OS2, but that behave differently in each environment, use the %_DOS 
  8127. variable to make the distinction.  For example, this batch file fragment uses 
  8128. the INPUT command to accept a string if it is run under 4OS2, but uses the 
  8129. GUI-style  QUERYBOX if it is run under Take Command: 
  8130.  
  8131.         iff "%_dos" == "PM" then
  8132.            querybox "Enter your name:  " %%name
  8133.         else
  8134.            input "Enter your name:  " %%name
  8135.         endiff
  8136.  
  8137. Aliases and batch files which simply manipulate files or use other internal 
  8138. commands should work with little or no change under Take Command. However, as a 
  8139. general rule, you should test any batch file developed for 4OS2 or CMD.EXE 
  8140. before assuming it will do exactly what you want under Take Command.  Pay 
  8141. particular attention to batch files which run complex sequences of external 
  8142. programs. 
  8143.  
  8144. If you use aliases or batch files to perform a sequence which mixes internal 
  8145. commands and DOS applications, the sequence may not work the way you expect 
  8146. under Take Command.  For example, suppose you have an alias that changes the 
  8147. screen color, starts a DOS application, and then resets the color again.  If 
  8148. the DOS application is started in a separate window the color changes will not 
  8149. affect it -- a contingency you probably didn't have to consider when you wrote 
  8150. the batch file. 
  8151.  
  8152. You may also find that you want to take advantage of some of the new features 
  8153. of Take Command to improve your batch files.  For example, the START command 
  8154. offers additional flexibility in starting applications.  MSGBOX and QUERYBOX 
  8155. can be used to create OS/2 GUI-style input prompts, and KEYSTACK and ACTIVATE 
  8156. will help control your OS/2 applications. 
  8157.  
  8158. Once you get used to these enhancements and minor differences you'll find that 
  8159. you can use Take Command to manage your system using the same techniques and 
  8160. features you are already familiar with from your experience with 4OS2 or 
  8161. CMD.EXE. 
  8162.  
  8163.  
  8164. ΓòÉΓòÉΓòÉ 5. The Take Command Window ΓòÉΓòÉΓòÉ
  8165.  
  8166. The Take Command window has five parts: the title bar, menu bar, toolbar, 
  8167. command window, and status bar. 
  8168.  
  8169. The command window accepts your input at the prompt, and displays Take 
  8170. Command's output. You can use the scroll bars or the up arrow and down arrow 
  8171. keys to view text that has scrolled off the window.  You can also save the 
  8172. contents of the command window and scrollback buffer to a file, copy text from 
  8173. the command window to the clipboard, and copy text from the clipboard or the 
  8174. command window to the command line. 
  8175.  
  8176. The next few sections discuss the menu bar, tool bar, and status bar portions 
  8177. of the Take Command screen. 
  8178.  
  8179.  
  8180. ΓòÉΓòÉΓòÉ 5.1. Take Command Menus ΓòÉΓòÉΓòÉ
  8181.  
  8182. Like all OS/2 PM applications, Take Command displays a menu bar along the top 
  8183. of the Take Command window.  To select a particular menu item, click once on 
  8184. the menu heading, or use Alt+x where "x" is the underlined letter on the menu 
  8185. bar (for example, Alt+F displays the File menu). 
  8186.  
  8187. The items on the menu bar allow you to select a variety of Take Command 
  8188. features: 
  8189.  
  8190.             File Menu 
  8191.             Edit Menu 
  8192.             Apps Menu 
  8193.             Setup Menu 
  8194.             Utilities Menu 
  8195.             Help Menu 
  8196.  
  8197.  
  8198. ΓòÉΓòÉΓòÉ 5.1.1. File Menu ΓòÉΓòÉΓòÉ
  8199.  
  8200. The File menu allows you to save or print the screen buffer, or exit Take 
  8201. Command. 
  8202.  
  8203.  Save to File... 
  8204.      Saves the contents of the screen buffer to a file.  A Save As dialog box 
  8205.      appears in which you can enter the name of the file that you wish to use. 
  8206.  
  8207.  Print... 
  8208.      Sends the contents of the screen buffer to the printer.  A Print dialog 
  8209.      box appears in which you can select print options. 
  8210.  
  8211.  Refresh 
  8212.      Redraws everything on the Take Command screen. 
  8213.  
  8214.  Shutdown 
  8215.      Shuts down OS/2. 
  8216.  
  8217.  Exit 
  8218.      Ends the current Take Command session. 
  8219.  
  8220.  
  8221. ΓòÉΓòÉΓòÉ 5.1.2. Edit Menu ΓòÉΓòÉΓòÉ
  8222.  
  8223. The Edit menu allows you to copy text between the Take Command window and the 
  8224. OS/2 clipboard. 
  8225.  
  8226. To use the the Copy command you must first select a block of text with the 
  8227. mouse or with the Select All command, below.  If you hold down the mouse button 
  8228. 2 while you select a block of text, that block will be copied to the clipboard 
  8229. automatically when you release the button. 
  8230.  
  8231. For more information on copying text see Highlighting and Copying Text. 
  8232.  
  8233.  Cut 
  8234.      Removes selected text from the command line and copies it to the OS/2 
  8235.      clipboard.  This option is only available when you have selected text on 
  8236.      the command line; it does not apply to selections anywhere else on the 
  8237.      screen, or in the scrollback buffer. 
  8238.  
  8239.  Copy 
  8240.      Copies selected text from the Take Command screen buffer to the OS/2 
  8241.      clipboard. 
  8242.  
  8243.  Paste 
  8244.      Copies text from the OS/2 clipboard to the command line. 
  8245.  
  8246.  Delete 
  8247.      Removes selected text from the command line.  Like Cut, this option is 
  8248.      only available when you have selected text on the command line. 
  8249.  
  8250.  Copy + Paste 
  8251.      Copies the selected text directly to the command line. 
  8252.  
  8253.  Select All 
  8254.      Marks the entire contents of the Take Command screen buffer as selected 
  8255.      text. 
  8256.  
  8257.  
  8258. ΓòÉΓòÉΓòÉ 5.1.3. Apps Menu ΓòÉΓòÉΓòÉ
  8259.  
  8260. The Apps menu allows you to start applications or switch to the desktop. 
  8261.  
  8262.  Run 
  8263.      Displays the run dialogfrom which you can run an application or batch 
  8264.      file.  Take Command remembers the commands you have run from this dialog 
  8265.      in the current session.  To select from this list click on the drop-down 
  8266.      arrow to the right of the "Command Line" field, or press Alt-down arrow 
  8267.      [Alt-].  To scroll through the list line by line press the down arrow 
  8268.      []. 
  8269.  
  8270.  Goto Desktop 
  8271.      Minimizes the Take Command window and switches the input focus to the OS/2 
  8272.      desktop. 
  8273.  
  8274.  OS/2 window 
  8275.      Starts a windowed OS/2 character mode session. 
  8276.  
  8277.  DOS window 
  8278.      Starts a windowed DOS session. 
  8279.  
  8280.  Win 3.x window 
  8281.      Starts a seamless WinOS2 window. 
  8282.  
  8283.  
  8284. ΓòÉΓòÉΓòÉ 5.1.4. Setup Menu ΓòÉΓòÉΓòÉ
  8285.  
  8286. The Setup menu lets you control the configuration of Take Command. 
  8287.  
  8288.  Configure Take Command 
  8289.      Opens the configuration notebook which you can use to change the 
  8290.      configuration of Take Command. 
  8291.  
  8292.  Configure Tool Bar 
  8293.      Opens the toolbar dialog, to allow you to create or modify buttons for the 
  8294.      Take Command tool bar. 
  8295.  
  8296.  Configure TTY Apps 
  8297.      Opens the TTY applications dialogwhich allows you to configure 
  8298.      character-mode applications to run inside the Take Command window. 
  8299.  
  8300.  Font 
  8301.      Displays a font selection submenu with three choices.  Each choice opens a 
  8302.      standard dialog box from which you can select the font and type size you 
  8303.      want: 
  8304.  
  8305.           Command window:          Selects the font for the main Take Command 
  8306.                                    window. You can choose any monospaced font 
  8307.                                    that has been properly installed in OS/2. 
  8308.                                    Note:  Some fonts will not display all of 
  8309.                                    the characters used by Take Command.  In 
  8310.                                    particular, you may need to experiment to 
  8311.                                    see if the font you choose includes the 
  8312.                                    proper line drawing characters for the 
  8313.                                    DRAWBOX, DRAWHLINE, and DRAWVLINE commands. 
  8314.                                    The standard OS/2 monospaced fonts (Courier, 
  8315.                                    System Monospaced, and System VIO) do 
  8316.                                    include these characters when an English 
  8317.                                    language character set is used. 
  8318.  
  8319.           Tool bar:                Selects the font for the tool bar. 
  8320.  
  8321.           Status bar:              Selects the font for the status bar. 
  8322.  
  8323.  Logging 
  8324.      Controls logging via a submenu with two choices: 
  8325.  
  8326.           Command:         Enables or disables command logging using the 
  8327.                            default TCOS2LOG file or the file you have chosen 
  8328.                            with the LOG command or the LogName directive in the 
  8329.                            TCMDOS2.INI file. 
  8330.  
  8331.           History:         Enables or disables command history logging using 
  8332.                            the default TCOS2LOG file or the file you have 
  8333.                            specified with the LOG /H command or the HistLogName 
  8334.                            directive in the TCMDOS2.INI file. 
  8335.  
  8336.  Show Tool Bar 
  8337.      Select this item to enable or disable the Take Command tool bar, which 
  8338.      appears near the top of the Take Command window.  The tool bar will not 
  8339.      appear unless at least one item has been defined for it with the Configure 
  8340.      Tool Bar command, above. 
  8341.  
  8342.  Show Status Bar 
  8343.      Select this item to enable or disable the Take Command status bar, which 
  8344.      appears near the bottom of the Take Command window. 
  8345.  
  8346.  
  8347. ΓòÉΓòÉΓòÉ 5.1.5. Utilities Menu ΓòÉΓòÉΓòÉ
  8348.  
  8349. The Utilities menu invokes dialogs to search for files and text or to set up 
  8350. Take Command aliases, environment variables, or file descriptions.  It can also 
  8351. start your editor. 
  8352.  
  8353.  Search Files/Text 
  8354.      Opens the search files dialog which lets you search for files or text 
  8355.      interactively (see FFIND to search from the command line). 
  8356.  
  8357.  Descriptions 
  8358.      Opens the descriptions dialog in which you can view and change the 
  8359.      descriptions of files in any directory available on your system.  See 
  8360.      DESCRIBE for details on file descriptions. 
  8361.  
  8362.  Aliases 
  8363.      Opens the aliases dialog in which you can view and change the list of 
  8364.      current aliases.  You can also use this window to import aliases from a 
  8365.      file or save all current aliases in a file.  Any changes you make will 
  8366.      take effect as soon as you return to Take Command.  For more information 
  8367.      on aliases see the ALIAS command. 
  8368.  
  8369.  Environment 
  8370.      Opens the environment dialog in which you can view and change the current 
  8371.      environment.  Any changes you make will be immediately recorded in Take 
  8372.      Command's environment. 
  8373.  
  8374.  Editor 
  8375.      Starts the OS/2 E editor or any other editor you have specified with the 
  8376.      Editor directive in TCMDOS2.INI 
  8377.  
  8378.  
  8379. ΓòÉΓòÉΓòÉ 5.1.6. Help Menu ΓòÉΓòÉΓòÉ
  8380.  
  8381.  Help Index 
  8382.      Displays the index for the Take Command help. 
  8383.  
  8384.  General Help 
  8385.      Displays the table of contents for the Take Command help. 
  8386.  
  8387.  Keys Help 
  8388.      Displays help for the Take Command command line.  From this help page you 
  8389.      can select a subtopic which covers the keystroke information you need 
  8390.      (e.g. command line editing, command history window, etc.). 
  8391.  
  8392.  Product Information 
  8393.      Displays Take Command version, copyright, and license information. 
  8394.  
  8395.  
  8396. ΓòÉΓòÉΓòÉ 5.2. Tool Bar ΓòÉΓòÉΓòÉ
  8397.  
  8398. The Take Command screen has an optional Tool Bar that you can use to execute 
  8399. internal or external commands, aliases, or batch files with the click of a 
  8400. mouse. 
  8401.  
  8402. To create buttons for the Tool Bar, select Configure Tool Bar from the Setup 
  8403. menu.  This selection displays the tool bar dialog. 
  8404.  
  8405. You can define up to 24 Tool Bar buttons. 
  8406.  
  8407. When you first install Take Command a sample tool bar is included.  Use the 
  8408. tool bar dialog to remove or modify any of the sample buttons, or add buttons 
  8409. of your own. 
  8410.  
  8411. To enable or disable the Tool Bar, use the ToolBarOn directive in TCMDOS2.INI, 
  8412. the Tool Bar Enable setting on the Display page in the configuration notebook, 
  8413. or the Show Tool Bar command in the Setup menu . 
  8414.  
  8415. The configuration dialog and TCMDOS2.INI settings are modified when you enable 
  8416. and disable the tool bar from the Setup menu. This preserves the tool bar state 
  8417. when you close Take Command, and restores it the next time you start a Take 
  8418. Command session. 
  8419.  
  8420.  
  8421. ΓòÉΓòÉΓòÉ 5.3. Status Bar ΓòÉΓòÉΓòÉ
  8422.  
  8423. The Take Command screen has an optional Status Bar that shows information about 
  8424. your system .  To enable or disable the Status Bar, use the StatusBarOn 
  8425. directive in TCMDOS2 .INI, the Status Bar Enable setting on the Display page in 
  8426. the configuration notebook, or the Show Status Bar command in the Setup menu. 
  8427.  
  8428. The configuration dialog and TCMDOS2.INI settings are modified when you enable 
  8429. and disable the status bar from the Setup menu.  This preserves the tool bar 
  8430. state when you close Take Command, and restores it the next time you start a 
  8431. Take Command session. 
  8432.  
  8433. The Status Bar shows 5 pieces of information: 
  8434.  
  8435.     The Date, based on the OS/2 clock. 
  8436.     The Time, based on the OS/2 clock. 
  8437.     The size of the OS/2 swap file. 
  8438.     The state of the Caps Lock key on the keyboard. 
  8439.     The state of the Num Lock key on the keyboard. 
  8440.  
  8441. If the OS/2 swap file is not stored in the \OS2\SYSTEM directory of the boot 
  8442. drive, you must use the SwapFilePath directive in TCMDOS2.INI or Take Command 
  8443. will not be able to display the swap file size in the status bar. 
  8444.  
  8445.  
  8446. ΓòÉΓòÉΓòÉ 5.4. Dialogs ΓòÉΓòÉΓòÉ
  8447.  
  8448. The Take Command menus invoke several dialog boxes: 
  8449.  
  8450.     Save To File Dialog 
  8451.     Print Dialog 
  8452.     Run Dialog 
  8453.     Configuration Notebook 
  8454.     Toolbar Dialog 
  8455.     TTY Apps Dialog 
  8456.     Search Files Dialog 
  8457.     Descriptions Dialog 
  8458.     Aliases Dialog 
  8459.     Environment Dialog 
  8460.  
  8461.  
  8462. ΓòÉΓòÉΓòÉ 5.4.1. Save To File Dialog ΓòÉΓòÉΓòÉ
  8463.  
  8464. This standard "Save As" dialog box allows you to select the file to use to save 
  8465. the contents of the screen buffer. 
  8466.  
  8467.  
  8468. ΓòÉΓòÉΓòÉ 5.4.2. Print Dialog ΓòÉΓòÉΓòÉ
  8469.  
  8470. This dialog allows you to print the contents of the screen buffer.  You can 
  8471. select the printer to use, the print priority, and the number of copies. 
  8472.  
  8473. If you have selected some text in the buffer, the Selection checkbox is 
  8474. automatically marked.  If you leave it marked, Take Command prints only the 
  8475. selected text.  If you remove the check mark, the entire buffer is printed. 
  8476.  
  8477.  
  8478. ΓòÉΓòÉΓòÉ 5.4.3. Run Dialog ΓòÉΓòÉΓòÉ
  8479.  
  8480. The Apps / Run menu leads to the Run Program dialog.  In the Command Line edit 
  8481. box, you can enter the name of any executable program plus command-line 
  8482. parameters.  If you click on the arrow to the right of the edit box, the dialog 
  8483. displays a list of previous commands you have entered during the current Take 
  8484. Command session. 
  8485.  
  8486. The Normal, Minimized, and Maximized radio buttons determine the type of window 
  8487. that will be used for the program.  If you select Minimized, the program will 
  8488. start as an icon on the desktop or in the Minimized Window Viewer (depending on 
  8489. your system default location for minimized window icons).  Maximized starts the 
  8490. program in a full-screen window.  Normal lets the operating system select the 
  8491. size and position of the program's window. 
  8492.  
  8493. The Browse button leads to a standard file browser, from which you can select 
  8494. any executable program.  Your choice will be placed in the Command Line edit 
  8495. box, and you can add parameters before pressing Enter or selecting OK to run 
  8496. the program. 
  8497.  
  8498.  
  8499. ΓòÉΓòÉΓòÉ 5.4.4. Toolbar Dialog ΓòÉΓòÉΓòÉ
  8500.  
  8501. This dialog allows you to define or modify buttons on the tool bar . 
  8502.  
  8503. Select the button you want to define or modify in the box on the left. 
  8504.  
  8505. Enter the button's label and the command to be executed when you select the 
  8506. button in the fields at the bottom of the dialog box.  You can enter multiple 
  8507. commands in the Command field by separating them with the command separator 
  8508. character [&]. 
  8509.  
  8510. You can use the Browse button to find a path and filename to be entered at the 
  8511. beginning of the Command field. 
  8512.  
  8513. Before entering a command to start an application program, be sure to check 
  8514. whether the application must be started in a particular directory.  If so, you 
  8515. should use a CDD command in\ the Command field before the application name, for 
  8516. example: 
  8517.  
  8518.         cdd d:\source & d:\os2\apps\epm.exe
  8519.  
  8520. If the command line begins with an at-sign [@] it will not be added to the 
  8521. command history. Otherwise, all commands executed from the tool bar are stored 
  8522. in the history. 
  8523.  
  8524. Use the radio buttons to select how you want the command to be executed: 
  8525.  
  8526.         *   Echo means display the tool bar command on the command line, but do 
  8527.             not execute it.  You can add additional text to the line if you 
  8528.             wish, then press Enter to execute the command.  This is the default 
  8529.             setting. 
  8530.  
  8531.         *   Echo & Execute means display the tool bar command on the command 
  8532.             line, then execute it immediately, without waiting for you to press 
  8533.             Enter. 
  8534.  
  8535.         *   Execute w/o Echo means execute the tool bar command immediately, 
  8536.             without waiting for you to press Enter, and without displaying the 
  8537.             command. 
  8538.  
  8539.  The Font Size setting applies to all of the buttons on the tool bar. If you 
  8540.  make the font size too large buttons on the right hand end of the toolbar may 
  8541.  not be visible even if the Take Command window is expanded to fill the screen. 
  8542.  
  8543.  If you exit by choosing the OK button, any changes you have made will be saved 
  8544.  in the TCMDOS2.INI file, and reloaded automatically the next time you start 
  8545.  Take Command.  If you use the Cancel button, your changes will be discarded. 
  8546.  
  8547.  
  8548. ΓòÉΓòÉΓòÉ 5.4.5. TTY Apps Dialog ΓòÉΓòÉΓòÉ
  8549.  
  8550. This dialog allows you to specify which character-mode applications can be run 
  8551. within the Take Command window.  If you are not familiar with the issues 
  8552. involved in running character-mode applications inside the Take Command window, 
  8553. read the separate section on Starting Character-Mode Applications before using 
  8554. this dialog. 
  8555.  
  8556. The list box on the left shows currently defined TTY applications. 
  8557.  
  8558. The Command field shows the command line for the currently selected 
  8559. application.  You can specify an executable file name (e.g. CHKDSK.COM), or a 
  8560. full path name (e.g. C:\OS2\CHKDSK.COM).  If you use a full path name, the 
  8561. entry will apply only to that specific file.  If you use just the file name, 
  8562. the entry will apply to any file of that name, regardless of its location. 
  8563. (For advanced use of this field to name an entire directory of TTY 
  8564. applications, see the end of this section.) 
  8565.  
  8566. The OS/2 and DOS radio buttons control whether Take Command treats the 
  8567. application as a DOS or OS/2 program. 
  8568.  
  8569. The Enable checkbox enables or disables an application.  If the box is checked, 
  8570. the application will be run within the Take Command window.  If the box is not 
  8571. checked, the entry will be ignored.  This allows you to temporarily disable an 
  8572. application (without removing it from the list) in order to test its 
  8573. compatibility with Take Command's TTY application support. 
  8574.  
  8575. Your copy of Take Command comes with a list of applications which can be run 
  8576. within the Take Command window.  The list is visible when you open the dialog, 
  8577. and is also included in the README.DOC file. However, all applications in the 
  8578. list are initially disabled to ensure maximum compatibility.  This prevents 
  8579. problems if you have a program with the same name as one we tested, but which 
  8580. is not the same program or the same version.  To enable any application, select 
  8581. it and check the Enable box. 
  8582.  
  8583. To modify an entry which is already in the TTY applications list, select the 
  8584. application in the box on the left and press Enter (or double-click).  Modify 
  8585. the Command field, the application type (DOS or OS/2), and the Enable checkbox 
  8586. as desired. 
  8587.  
  8588. To add a new entry, select the Add button.  Fill in the Command field, set the 
  8589. application type, and check the Enable button if desired.  You can use the 
  8590. Browse button to find a path and filename to be entered at the beginning of the 
  8591. Command field.  After creating a new entry you must press Enter to copy the new 
  8592. entry to the listbox.  If you do not, the information about the new application 
  8593. will be discarded. 
  8594.  
  8595. To delete an entry, select it in the list box, then select the Delete button. 
  8596.  
  8597. If you exit by choosing the OK button, any changes you have made will be saved 
  8598. in the [TTYApps] of TCMDOS2.INI, and reloaded automatically the next time you 
  8599. start Take Command.  If you use the Cancel button, your changes will be 
  8600. discarded. 
  8601.  
  8602. In addition to the options described above, you can also enter a path without a 
  8603. filename in the Command field (e.g. C:\OS2UTILS).  This will tell Take Command 
  8604. to treat all DOS or OS/2 character-mode programs in the specified directory as 
  8605. TTY applications.  If you use this option the OS2, DOS, and Enable buttons 
  8606. apply to all applications in the specified directory.  This approach is useful 
  8607. if you have many applications of the same type in a single directory, but 
  8608. before you use it you should review the content of the directory carefully to 
  8609. be sure all the character-mode programs stored there are compatible with Take 
  8610. Command's TTY application support. 
  8611.  
  8612. If you do choose to configure an entire directory for TTY application support, 
  8613. you can create exceptions by entering specific filenames from that directory 
  8614. into the dialog as well.  For example, if you enable the directory C:\OS2UTILS 
  8615. for TTY support, you could also add a listing for C:\OS2UTILS\MYAPP.EXE (or 
  8616. simply for MYAPP.EXE, with no path), and make sure the Enable box is not 
  8617. checked for the MYAPP entry. This would prevent MYAPP.EXE from being treated as 
  8618. a TTY application despite the entry for the directory as a whole.  If you use 
  8619. this approach, the two listings can appear in any order. 
  8620.  
  8621. TTY application support for DOS programs depends on the TCNPDOS.COM file 
  8622. distributed with Take Command.  This file must be available in the same 
  8623. directory as TCMDOS2.EXE.  If it is not, Take Command will display an error 
  8624. message if you try to run a DOS application within the Take Command window. 
  8625.  
  8626.  
  8627. ΓòÉΓòÉΓòÉ 5.4.6. Search Files Dialog ΓòÉΓòÉΓòÉ
  8628.  
  8629. The Search Files/Text dialog box gives you the same features as the FFIND 
  8630. command, in dialog form. 
  8631.  
  8632. Enter the file name or names you wish search in the Files field.  You can use 
  8633. wildcards and include lists as part of the file name.  To select files from 
  8634. previous searches in the same Take Command session, click on the down arrow 
  8635. beside the Files field, or press the up arrow [] or down arrow [] while the 
  8636. input cursor is in the Files field.  You can also use the Browse button to find 
  8637. files to include in the search. 
  8638.  
  8639. Enter the text or hexadecimal values you are searching for in the Text field. 
  8640.  
  8641. Enter the drive(s) you want to search in the Disks field. 
  8642.  
  8643. The Match Case box, when it is selected, makes the search case-sensitive.  The 
  8644. Hex Search option signals that you are searching for hexadecimal values, not 
  8645. ASCII characters. 
  8646.  
  8647. If you enable All Lines, every line from every file that contains the search 
  8648. text will be displayed.  If this option is not enabled, only the first line 
  8649. from such a file will be displayed. 
  8650.  
  8651. Unless you enable the Hidden Files option, files with the hidden attribute will 
  8652. not be included in the search. 
  8653.  
  8654. The radio buttons in the Search area let you specify where you want to look for 
  8655. files. 
  8656.  
  8657. To start the search, press the Find button.  Once the search has started the 
  8658. Find button changes to a Stop button, which can use to interrupt the search 
  8659. before it is finished. 
  8660.  
  8661. Once Take Command has finished searching, you can save the list of matching 
  8662. files with the Export button. 
  8663.  
  8664. As you move the cursor over the list of matching files, information about each 
  8665. file appears below the file list.  If you select one of the matching files in 
  8666. the list (by double-clicking on it, or selecting it with the cursor and 
  8667. pressing Enter), Take Command will display another dialog with complete 
  8668. directory information about the file.  From that dialog you can Run the file 
  8669. (if it is an executable file, a batch file, or has an executable extension), 
  8670. display the file with the LIST command, or Edit the file.  When you exit from 
  8671. LIST or the editor, the original list of matching files will still be 
  8672. available. 
  8673.  
  8674.  
  8675. ΓòÉΓòÉΓòÉ 5.4.7. Descriptions Dialog ΓòÉΓòÉΓòÉ
  8676.  
  8677. This dialog allows you to create, modify, or delete file descriptions (if you 
  8678. are not familiar with Take Command file descriptions, see the DESCRIBE command 
  8679. for details). 
  8680.  
  8681. A list of files in the current directory is shown in the pane on the left side 
  8682. of the dialog.  As you move the cursor in the pane, the description for the 
  8683. file (if any) is shown in the Description field.  You can use this field to 
  8684. edit or create the selected file's description. 
  8685.  
  8686. After changing a description you must press Enter (or select the OK button and 
  8687. close the dialog) to record your changes on the disk.  If you do not (for 
  8688. example, if you change a description, then select another file without first 
  8689. pressing Enter), your changes will be discarded. 
  8690.  
  8691. If you click Cancel any changes to the current description are discarded, and 
  8692. the dialog is closed.  Cancel does not undo previous changes which were saved 
  8693. by pressing the Enter key as described above. 
  8694.  
  8695. To delete a description, select the file, move to the description field and 
  8696. delete all of the description text, then press Enter or click OK. 
  8697.  
  8698. To work in a different drive or directory, use the Drive and/or Directory 
  8699. fields on the right side of the dialog to select the desired location. 
  8700.  
  8701. The dialog automatically includes all files in the list.  To select a specific 
  8702. group of files of your own choosing, type a new filename in the Filename box. 
  8703.  
  8704.  
  8705. ΓòÉΓòÉΓòÉ 5.4.8. Aliases Dialog ΓòÉΓòÉΓòÉ
  8706.  
  8707. The current list of aliases is shown in the pane on the left of this dialog 
  8708. box.  As you move the cursor in the pane, the name of the alias under the 
  8709. cursor is shown in the Name field and its definition is shown in the Value 
  8710. field.  You can use these fields to edit the alias. 
  8711.  
  8712. To add a new alias to the list, use the Add button.  The Name and Value fields 
  8713. will be cleared so you can enter new values in each.  To save the new entry, 
  8714. switch to a different entry or press Enter. 
  8715.  
  8716. The Delete button deletes the highlighted alias. 
  8717.  
  8718. The Import button reads a list of aliases from a file (similar to the ALIAS /R 
  8719. command).  The Export button writes the current list to a file. 
  8720.  
  8721. Changes you make in this dialog are not saved in the alias list until you click 
  8722. the OK button.  If you click Cancel the changes are discarded. 
  8723.  
  8724.  
  8725. ΓòÉΓòÉΓòÉ 5.4.9. Environment Dialog ΓòÉΓòÉΓòÉ
  8726.  
  8727. The current environment variables are shown in the pane on the left of this 
  8728. dialog box.  As you move the cursor in the pane, the name of each entry appears 
  8729. in the Name field and its value appears in the Value field.  You can use these 
  8730. fields to edit the environment entry. 
  8731.  
  8732. To add a entry to the list, use the Add button.  The Name and Value fields will 
  8733. be cleared so you can enter new values in each. To save the new entry, switch 
  8734. to a different entry or press Enter. 
  8735.  
  8736. The Delete button deletes the highlighted environment variable. 
  8737.  
  8738. The Import button reads a list of environment variables from a file (similar to 
  8739. the SET /R command). The Export button writes the current list to a file. 
  8740.  
  8741. Changes you make in this dialog are not saved in the environment until you 
  8742. click the OK button.  If you click Cancel the changes are discarded. 
  8743.  
  8744.  
  8745. ΓòÉΓòÉΓòÉ 5.5. Using the Scrollback Buffer ΓòÉΓòÉΓòÉ
  8746.  
  8747. Take Command retains the text displayed on its screen in a "scrollback buffer". 
  8748.  
  8749. You can scroll through this buffer using the mouse and the vertical scroll bar 
  8750. at the right side of the Take Command window, just as you can in any OS/2 GUI 
  8751. application. 
  8752.  
  8753. You can also use the up-arrow [] and down-arrow [] keys to scroll the display 
  8754. one line at a time from the keyboard, and the PgUp and PgDn keys to scroll one 
  8755. page at a time. 
  8756.  
  8757. If you enter text on the command line, Take Command will automatically return 
  8758. to the bottom of the buffer to display the text. 
  8759.  
  8760. If you prefer to use the arrow and PgUp keys to access the command history (as 
  8761. in 4OS2), see the SwapScrollKeys directive in TCMDOS2.INI, or the corresponding 
  8762. option on the Command Line page of the configuration dialogs.  SwapScrollKeys 
  8763. switches the keystroke mapping so that the , , and PgUp keys manipulate the 
  8764. command history, and Ctrl-, Ctrl-, Ctrl-PgUp, and Ctrl-PgDn are used to 
  8765. control the scrollback buffer.  For more details see Scrolling and History 
  8766. Keystrokes. 
  8767.  
  8768. You can set the size of the scrollback buffer on the Display page of the 
  8769. configuration notebook (available from the Setup menu), or with the 
  8770. ScreenBufSize directive in TCMDOS2.INI. 
  8771.  
  8772. To clear the entire scrollback buffer, use the CLS /C command. 
  8773.  
  8774.  
  8775. ΓòÉΓòÉΓòÉ 5.6. Highlighting and Copying Text ΓòÉΓòÉΓòÉ
  8776.  
  8777. While you are working at the Take Command prompt you can use common keystrokes 
  8778. to edit commands, and use the OS/2 clipboard to copy text between Take Command 
  8779. and other applications. 
  8780.  
  8781. To copy text from the Take Command window to the clipboard, first use the mouse 
  8782. to highlight the text,  then press Ctrl-Ins, or use the Copy command on the 
  8783. Edit menu.  You can also mark the text using mouse button 2; in this case the 
  8784. text will be copied to the clipboard immediately when you release the mouse 
  8785. button. 
  8786.  
  8787. To highlight text on the command line use the Shift key in conjunction with the 
  8788. Left, Right, Ctrl-Left, Ctrl-Right, Home, and End cursor movement keys.  The 
  8789. Del key will delete any highlighted text on the command line, or you can type 
  8790. new text to replace the highlighted text. 
  8791.  
  8792. While the Take Command window contains text, it is not a document window like 
  8793. those used by word processors and other similar software, and you cannot move 
  8794. the cursor throughout the window as you can in text processing programs. As a 
  8795. result, you cannot use the OS/2 shortcut keys like Shift-Left or Shift-Right to 
  8796. highlight text in the window.  These keys work only at the command line; to 
  8797. highlight text elsewhere in the window you must use the mouse.  You can also 
  8798. select all of the text in the Take Command screen buffer by using the Select 
  8799. All command on the Edit menu. 
  8800.  
  8801. To copy text from the clipboard to the command line use Shift-Ins, or the Copy 
  8802. command on the Edit menu. 
  8803.  
  8804. To paste text from elsewhere in the Take Command window directly onto the 
  8805. command line, highlight the text with the mouse and press Ctrl-Shift-Ins, or 
  8806. use the Copy+Paste command on the Edit menu.  This is equivalent to 
  8807. highlighting the text and pressing Ctrl-Ins followed by Shift-Ins.  It's a 
  8808. convenient way to copy a filename from a previous DIR or other command directly 
  8809. to the command line. 
  8810.  
  8811. You should use caution when pasting text containing carriage return or line 
  8812. feed characters onto the command line.  If the text you insert contains one of 
  8813. these characters the command line will be executed just as if you had pressed 
  8814. Enter.  If you insert multiple lines, the text will be treated just like 
  8815. multiple lines of commands typed at the prompt. 
  8816.  
  8817. You can also use OS/2's Drag and Drop facility to paste a filename from another 
  8818. application onto the command line. 
  8819.  
  8820.  
  8821. ΓòÉΓòÉΓòÉ 5.7. Cursor Display on LCD Screens ΓòÉΓòÉΓòÉ
  8822.  
  8823. If you use a laptop or LCD screen and find the "I-Beam" cursor in the Take 
  8824. Command window difficult to see, use an IBeamCursor = No directive in the 
  8825. [TakeCommand] section of TCMDOS2.INI to force the use of an arrow cursor in all 
  8826. parts of the window. 
  8827.  
  8828.  
  8829. ΓòÉΓòÉΓòÉ 6. Batch Files ΓòÉΓòÉΓòÉ
  8830.  
  8831. A batch file is a file that contains a list of commands to execute.  Take 
  8832. Command reads and interprets each line as if it had been typed at the keyboard. 
  8833. Like aliases, batch files are handy for automating computing tasks.  Unlike 
  8834. aliases, batch files can be as long as you wish.  Batch files take up separate 
  8835. disk space for each file, and can't usually execute quite as quickly as 
  8836. aliases, since they must be read from the disk. 
  8837.  
  8838. The topics included in this section are: 
  8839.  
  8840.     .BAT, .CMD, and .BTM Files 
  8841.     Echoing in Batch Files 
  8842.     Batch File Line Continuation 
  8843.     Batch File Parameters 
  8844.     Automatic Batch Files 
  8845.     Batch File Compression 
  8846.     Argument Quoting 
  8847.     4DOS, 4OS2, 4DOS/NT and Take Command Compatibility 
  8848.     REXX Support 
  8849.     EXTPROC Support 
  8850.  
  8851.  
  8852. ΓòÉΓòÉΓòÉ 6.1. .BAT, .CMD, and .BTM Files ΓòÉΓòÉΓòÉ
  8853.  
  8854. A Take Command batch file can run in two different modes.  In the first, 
  8855. traditional mode, each line of the batch file is read and executed 
  8856. individually, and the file is opened and closed to read each line.  In the 
  8857. second mode the batch file is opened once, the entire file is read into memory, 
  8858. and the file is closed.  The second mode can be 5 to 10 times faster, 
  8859. especially if most of the commands in the batch file are internal commands. 
  8860. However, only the first mode can be used for self-modifying batch files (which 
  8861. are rare), and for batch files larger than 64K bytes. 
  8862.  
  8863. The batch file's extension determines its mode.  Files with a .BAT or .CMD 
  8864. extension are run in the slower, traditional mode.  Files with a .BTM extension 
  8865. are run in the faster, more efficient mode.  You can change the execution mode 
  8866. inside a batch file with the LOADBTM command. 
  8867.  
  8868.  
  8869. ΓòÉΓòÉΓòÉ 6.2. Echoing in Batch Files ΓòÉΓòÉΓòÉ
  8870.  
  8871. By default, each line in a batch file is displayed or "echoed" as it is 
  8872. executed.  You can change this behavior, if you want, in several different 
  8873. ways: 
  8874.  
  8875. Any batch file line that begins with an [@] symbol will not be displayed. 
  8876.  
  8877. The display can be turned off and on within a batch file with the ECHO OFF and 
  8878. ECHO ON commands. 
  8879.  
  8880. The default setting can be changed with the SETDOS /V command or the BatchEcho 
  8881. directive in the .INI file. 
  8882.  
  8883. For example, the following line turns off echoing inside a batch file. The [@] 
  8884. symbol keeps the batch file from displaying the ECHO OFF command: 
  8885.  
  8886.         @echo off
  8887.  
  8888. Take Command also has a command line echo that is unrelated to the batch file 
  8889. echo setting.  See ECHO for details about both settings. 
  8890.  
  8891.  
  8892. ΓòÉΓòÉΓòÉ 6.3. Batch File Line Continuation ΓòÉΓòÉΓòÉ
  8893.  
  8894. Take Command will combine multiple lines in the batch file into a single line 
  8895. for processing when you include the escape character as the very last character 
  8896. of each line to be combined (except the last).  The default escape character is 
  8897. a caret [^].  For example: 
  8898.  
  8899.         [c:\] echo The quick brown fox jumped over the lazy^
  8900.         sleeping^
  8901.         dog. > alphabet
  8902.  
  8903. You cannot use this technique to extend a batch file line beyond the normal 
  8904. line length limit of 1,023 characters. 
  8905.  
  8906.  
  8907. ΓòÉΓòÉΓòÉ 6.4. Batch File Parameters ΓòÉΓòÉΓòÉ
  8908.  
  8909. Like aliases and application programs, batch files can examine the command line 
  8910. that is used to invoke them.  The command tail (everything on the command line 
  8911. after the batch file name) is separated into individual parameters (also called 
  8912. arguments or batch variables) by scanning for the spaces, tabs, and commas that 
  8913. separate the parameters.  A batch file can work with the individual parameters 
  8914. or with the command tail as a whole. 
  8915.  
  8916. These parameters are numbered from %1 to %127. %1 refers to the first parameter 
  8917. on the command line, %2 to the second, and so on.  It is up to the batch file 
  8918. to determine the meaning of each parameter.  You can use quotation marks to 
  8919. pass spaces, tabs, commas, and other special characters in a batch file 
  8920. parameter; see Argument Quoting for details. 
  8921.  
  8922. Parameters that are referred to in a batch file, but which are missing on the 
  8923. command line, appear as empty strings inside the batch file.  For example, if 
  8924. you start a batch file and put two parameters on the command line, any 
  8925. reference in the batch file to %3, or any higher-numbered parameter, will be 
  8926. interpreted as an empty string. 
  8927.  
  8928. A batch file can also work with three special parameters: %0 contains the name 
  8929. of the batch file as it was entered on the command line, %# contains the number 
  8930. of command line arguments, and %n$ contains the complete command-line tail 
  8931. starting with argument number n (for example,%3$ means the third parameter and 
  8932. all those after it).  The default value of n is 1, so %$ contains the entire 
  8933. command tail.  The values of these special parameters will change if you use 
  8934. the SHIFT command. 
  8935.  
  8936. For example, if your batch file interprets the first argument as a subdirectory 
  8937. name then the following line would move to the specified directory: 
  8938.  
  8939.         cd %1
  8940.  
  8941. Batch files can also use environment variables, internal variables, and 
  8942. variable functions. 
  8943.  
  8944.  
  8945. ΓòÉΓòÉΓòÉ 6.5. Automatic Batch Files ΓòÉΓòÉΓòÉ
  8946.  
  8947. Each time Take Command starts, it looks for an automatic batch file called 
  8948. TCSTART.BTM or TCSTART.CMD.  If the TCSTART batch file is not in the same 
  8949. directory as Take Command itself, you should use the TCSTARTPath directive in 
  8950. your .INI file to specify its location.  TCSTART is optional, so Take Command 
  8951. will not display an error message if it cannot find the file. 
  8952.  
  8953. Whenever an Take Command session ends, it runs a second automatic batch file 
  8954. called TCEXIT.BTM or TCEXIT.CMD. This file, if you use it, should be in the 
  8955. same directory as your TCSTART batch file.  Like TCSTART, TCEXIT is optional. 
  8956. It is not necessary in most circumstances, but it is a convenient place to put 
  8957. commands to save information such as a history list before Take Command ends, 
  8958. or LOG the end of the session. 
  8959.  
  8960.  
  8961. ΓòÉΓòÉΓòÉ 6.6. Batch File Compression ΓòÉΓòÉΓòÉ
  8962.  
  8963. You can compress your .BTM files with a program called BATCOMP.EXE, which is 
  8964. distributed with Take Command.  This program condenses batch files by about a 
  8965. third and makes them unreadable with the LIST command and similar utilities. 
  8966. Compressed batch files run at approximately the same speed as regular .BTM 
  8967. files. 
  8968.  
  8969. You may want to consider compressing batch files if you need to distribute them 
  8970. to others and keep your original code secret or prevent your users from 
  8971. altering them.  You may also want to consider compressing batch files to save 
  8972. some disk space on the systems where the compressed files are used. 
  8973.  
  8974. The full syntax for the batch compression program is 
  8975.  
  8976.         BATCOMP [/O] input file [output file ]
  8977.  
  8978. You must specify the full name of the input file, including its extension, on 
  8979. the BATCOMP command line.  If you do not specify the output file, BATCOMP will 
  8980. use the same base name as the input file and add a .BTM extension. BATCOMP will 
  8981. also add a .BTM extension if you specify a base name for the output file 
  8982. without an extension.  For example, to compress MYBATCH.CMD and save the result 
  8983. as MYBATCH.BTM, you can use any of these three commands: 
  8984.  
  8985.         [c:\] batcomp mybatch.cmd
  8986.         [c:\] batcomp mybatch.cmd mybatch
  8987.         [c:\] batcomp mybatch.cmd mybatch.btm
  8988.  
  8989. If the output file (MYBATCH.BTM in the examples above) already exists, BATCOMP 
  8990. will prompt you before overwriting the file.  You can disable the prompt by 
  8991. including /O on the BATCOMP command line immediately before the input file 
  8992. name.  Even if you use the /O option, BATCOMP will not compress a file into 
  8993. itself. 
  8994.  
  8995. JP Software does not provide a utility to decompress batch files.  If you use 
  8996. BATCOMP.EXE, make sure that you also keep a copy of the original batch file for 
  8997. future inspection or modification. 
  8998.  
  8999. Each of our command processors includes its own version of BATCOMP.EXE, set up 
  9000. to run under the corresponding operating system. However, the output produced 
  9001. by each program is the same, so a batch file compressed with any version of 
  9002. BATCOMP can be used with any JP Software command processor. 
  9003.  
  9004. If you plan to distribute batch files to users of different platforms, see 
  9005. 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility. 
  9006.  
  9007.  
  9008. ΓòÉΓòÉΓòÉ 6.7. Argument Quoting ΓòÉΓòÉΓòÉ
  9009.  
  9010. As it parses the command line, Take Command looks for the ampersand [&] command 
  9011. separator, conditional commands (|| or &&), white space (spaces, tabs, and 
  9012. commas), percent signs [%] which indicate variables or batch file arguments to 
  9013. be expanded, and redirection and piping characters (>, <, or |). 
  9014.  
  9015. Normally, these special characters cannot be passed to a command as part of an 
  9016. argument.  However, you can include any of the special characters in an 
  9017. argument by enclosing the entire argument in single back quotes [`] or double 
  9018. quotes ["].  Although both back quotes and double quotes will let you build 
  9019. arguments that include special characters, they do not work the same way. 
  9020.  
  9021. No alias or variable expansion is performed on an argument enclosed in back 
  9022. quotes.  Redirection symbols inside the back quotes are ignored. The back 
  9023. quotes are removed from the command line before the command is executed. 
  9024.  
  9025. No alias expansion is performed on expressions enclosed in double quotes. 
  9026. Redirection symbols inside double quotes are ignored. However, variable 
  9027. expansion is performed on expressions inside double quotes.  The double quotes 
  9028. themselves will be passed to the command as part of the argument. 
  9029.  
  9030. For example, suppose you have a batch file CHKNAME.BTM which expects a name as 
  9031. its first parameter (%1).  Normally the name is a single word.  If you need to 
  9032. pass a two-word name with a space in it to this batch file you could use the 
  9033. command: 
  9034.  
  9035.         [c:\] chkname `MY NAME`
  9036.  
  9037. Inside the batch file, %1 will have the value MY NAME, including the space. 
  9038. The back quotes caused Take Command to pass the string to the batch file as a 
  9039. single argument.  The quotes keep characters together and reduce the number of 
  9040. arguments in the line. 
  9041.  
  9042. When an alias is defined in a batch file or from the command line, its argument 
  9043. can be enclosed in back quotes to prevent the expansion of replaceable 
  9044. parameters, variables, and multiple commands until the alias is invoked. See 
  9045. ALIAS for details. 
  9046.  
  9047. You can disable and re-enable back quotes and double quotes with the SETDOS /X 
  9048. command. 
  9049.  
  9050.  
  9051. ΓòÉΓòÉΓòÉ 6.8. 4DOS, 4OS2, 4DOS/NT, and Take Command Compatibility ΓòÉΓòÉΓòÉ
  9052.  
  9053. If you use two or more of our products, or if you want to share aliases and 
  9054. batch files with users of different products, you need to be aware of the 
  9055. differences in three important characters:  the Command Separator (see Multiple 
  9056. Commands), the Escape Character (see Escape Character), and the Parameter 
  9057. Character (see Batch File Parameters). 
  9058.  
  9059. The default values of each of these characters in each product is shown in the 
  9060. following chart (in this section, <Ctrl-X> stands for the ASCII Ctrl-X 
  9061. character, numeric value 24.  This character appears on your screen as an 
  9062. up-arrow [].): 
  9063.  
  9064.         Character           4DOS Default   4OS2 and Take Command Default
  9065.  
  9066.         Command Separator        ^              &
  9067.         Escape Character         <Ctrl-X>       ^
  9068.         Parameter Character      &              $
  9069.  
  9070. In your batch files and aliases, and even at the command line, you can smooth 
  9071. over these differences in two ways: 
  9072.  
  9073.         *   Select a consistent set of characters with .INI file configuration 
  9074.             directives or the SETDOS command.  For example, to set the Take 
  9075.             Command characters to match 4DOS, use: 
  9076.  
  9077.                                 CommandSep = ^
  9078.                                 EscapeChar = <Ctrl-X>
  9079.                                 ParameterChar = &
  9080.  
  9081.             in TCMDOS2.INI. 
  9082.  
  9083.         *   Use internal variables that contain the current special character, 
  9084.             rather than using the character itself (see + and =).  For example, 
  9085.             this command: 
  9086.  
  9087.                                 if "%1" == "" (echo Argument missing! ^ quit)
  9088.  
  9089.             will only work if the command separator is a caret. However, this 
  9090.             version works regardless of the current command separator: 
  9091.  
  9092.                                 if "%1" == "" (echo Argument missing! %+ quit)
  9093.  
  9094.  
  9095.  The following chart shows the correspondence between the appropriate SETDOS 
  9096.  command options, .INI file directives, and internal variables: 
  9097.  
  9098.           Special                 SETDOS   INI File     Internal
  9099.           Character               Switch   Directive    Variable
  9100.  
  9101.           Command Separator        /C      CommandSep     %+
  9102.           Escape Character         /E      EscapeChar     %=
  9103.           Parameter Character      /P      ParameterChar  (none)
  9104.  
  9105.  
  9106. ΓòÉΓòÉΓòÉ 6.9. REXX Support ΓòÉΓòÉΓòÉ
  9107.  
  9108. REXX is a a powerful file and text processing language developed by IBM, and 
  9109. available on many PC and other platforms.  REXX is an ideal extension to the 
  9110. Take Command batch language, especially if you need advanced string processing 
  9111. capabilities. 
  9112.  
  9113. The REXX language is not built into Take Command.  You can use the REXX 
  9114. provided with OS/2, or Personal REXX for OS/2 (a faster, more capable version 
  9115. of REXX), developed by Quercus Systems of Saratoga, CA. (Personal REXX is 
  9116. available from JP Software or directly from Quercus Systems.) 
  9117.  
  9118. Take Command's REXX support will also work with other REXX processors such as 
  9119. PMREXX, VX-REXX.  It does not work with IBM's VREXX, because the internal 
  9120. design of VREXX does not perrmit reliable execution of REXX scripts from 
  9121. Presentation Manager programs like Take Command. 
  9122.  
  9123. REXX programs are stored in .CMD files.  When Take Command loads a .CMD file, 
  9124. it checks to see if the first two characters of the file are "/*"; if so, it 
  9125. passes the file to the REXX DLL for execution. 
  9126.  
  9127.  
  9128. ΓòÉΓòÉΓòÉ 6.10. EXTPROC Support ΓòÉΓòÉΓòÉ
  9129.  
  9130. Take Command offers an external processor (EXTPROC) option for batch files that 
  9131. lets you define an external program to process a particular .CMD file. To 
  9132. identify a .CMD file to be used with an external processor, place the string 
  9133. "EXTPROC" as the first word on the first line of the file, followed by the name 
  9134. of the external program that should be called.  Take Command will start the 
  9135. program and pass it the name of the .CMD  file and any command-line arguments 
  9136. that were entered. 
  9137.  
  9138. For example, suppose GETDATA.CMD contains the following lines: 
  9139.  
  9140.         EXTPROC D:\DATAACQ\DATALOAD.EXE
  9141.         OPEN PORT1
  9142.         READ 4000
  9143.         DISKWRITE D:\DATAACQ\PORT1\RAW
  9144.  
  9145. Then if you entered the command: 
  9146.  
  9147.         [d:\dataacq] getdata /p17
  9148.  
  9149. Take Command would read the GETDATA.CMD file, determine that it began with an 
  9150. EXTPROC command, read the name of the processor program, and then execute the 
  9151. command: 
  9152.  
  9153.         D:\DATAACQ\DATALOAD.EXE D:\DATAACQ\GETDATA.CMD /p17
  9154.  
  9155. The hypothetical DATALOAD.EXE program would then be responsible for reopening 
  9156. the GETDATA.CMD file, ignoring the EXTPROC line at the start, and interpreting 
  9157. the other instructions in the file. It would also have to respond appropriately 
  9158. to the command-line parameter entered (/p17). 
  9159.  
  9160. Do not try to use Take Command as the external processor named on the EXTPROC 
  9161. line in the .CMD file.  It will interpret the EXTPROC line as a command to 
  9162. re-open themselves.  The result will be an infinite loop that will continue 
  9163. until the computer runs out of resources and locks up. 
  9164.  
  9165.  
  9166. ΓòÉΓòÉΓòÉ 7. The Environment ΓòÉΓòÉΓòÉ
  9167.  
  9168. The environment is a collection of information about your computer that every 
  9169. program receives.  Each entry in the environment consists of a variable name, 
  9170. followed by an equal sign and a string of text.  You can automatically 
  9171. substitute the text for the variable name in any command. To create the 
  9172. substitution, include a percent sign [%] and a variable name on the command 
  9173. line or in an alias or batch file. 
  9174.  
  9175. The following environment variables have special meanings in Take Command: 
  9176.  
  9177.     CDPATH 
  9178.     CMDLINE 
  9179.     COLORDIR 
  9180.     PATH 
  9181.     PROMPT 
  9182.  
  9183. Take Command also supports two special types of variables. Internal variables 
  9184. are similar to environment variables, but are stored internally within Take 
  9185. Command, and are not visible in the environment.  They provide information 
  9186. about your system for use in batch files and aliases.  Variable functions are 
  9187. referenced like environment variables, but perform additional functions like 
  9188. file handling, string manipulation and arithmetic calculations. 
  9189.  
  9190. The SET command is used to create environment variables. For example, you can 
  9191. create a variable named BACKUP like this: 
  9192.  
  9193.         [c:\] set BACKUP=*.bak;*.bk!;*.bk
  9194.  
  9195. If you then type 
  9196.  
  9197.         [c:\] del %BACKUP
  9198.  
  9199. it is equivalent to the following command: 
  9200.  
  9201.         del *.bak;*.bk!;*.bk
  9202.  
  9203. The variable names you use this way may contain any alphabetic or numeric 
  9204. characters, the underscore character [_], and the dollar sign [$].  You can 
  9205. force acceptance of other characters by including the full variable name in 
  9206. square brackets, like this: %[AB##2]. You can also "nest" environment variables 
  9207. using square brackets.  For example %[%var1] means "the contents of the 
  9208. variable whose name is stored in VAR1".  A variable referenced with this 
  9209. technique cannot contain more than 255 characters of information.  Nested 
  9210. variable expansion can be disabled with the SETDOS /X command. 
  9211.  
  9212. In Take Command the size of the environment is set automatically, and increased 
  9213. as needed when you add variables. 
  9214.  
  9215. The trailing percent sign that was traditionally required for environment 
  9216. variable names is not usually required in Take Command, which accepts any 
  9217. character that cannot be part of a variable name as the terminator. However, 
  9218. the trailing percent can be used to maintain compatibility. 
  9219.  
  9220. The trailing percent sign is needed if you want to join two variable values. 
  9221. The following examples show the possible interactions between variables and 
  9222. literal strings.  First, create two environment variables called ONE and TWO 
  9223. this way: 
  9224.  
  9225.         [c:\] set ONE=abcd
  9226.         [c:\] set TWO=efgh
  9227.  
  9228. Now the following combinations produce the output text shown: 
  9229.  
  9230.         %ONE%TWOabcdTWO      ("%ONE%" + "TWO")
  9231.         %ONE%TWO%abcdTWO     ("%ONE%" + "TWO%")
  9232.         %ONE%%TWOabcdefgh    ("%ONE%" + "%TWO")
  9233.         %ONE%%TWO%abcdefgh   ("%ONE%" + "%TWO%")
  9234.         %ONE%[TWO]abcd[TWO]  ("%ONE%" + "[TWO]")
  9235.         %ONE%[TWO]%abcd[TWO] ("%ONE%" + "[TWO]%")
  9236.         %[ONE]%TWOabcdefgh   ("%[ONE]" + "%TWO")
  9237.         %[ONE]%TWO%abcdefgh  ("%[ONE]" + "%TWO%")
  9238.  
  9239. If you want to pass a percent sign to a command, or a string which includes a 
  9240. percent sign, you must use two percent signs in a row. Otherwise, the single 
  9241. percent sign will be seen as the beginning of a variable name and will not be 
  9242. passed on to the command.  For example, to display the string "We're with you 
  9243. 100%" you would use the command: 
  9244.  
  9245.         echo We're with you 100%%
  9246.  
  9247. You can also use back quotes around the text, rather than a double percent 
  9248. sign.  See Argument Quoting for details. 
  9249.  
  9250.  
  9251. ΓòÉΓòÉΓòÉ 7.1. CDPATH ΓòÉΓòÉΓòÉ
  9252.  
  9253. CDPATH tells Take Command where to search for directories specified by the CD, 
  9254. CDD, and PUSHD commands and in automatic directory changes.  (_CDPATH can be 
  9255. used as an alternative to CDPATH if you are using Microsoft Bookshelf, which 
  9256. uses a CDPATH variable for its own purposes.) 
  9257.  
  9258. CDPATH is composed of a list of directories, separated by semicolons [;].  If 
  9259. CD, CDD, PUSHD, or an automatic directory change can't locate the specified 
  9260. directory to change to, they will append the specified directory name to each 
  9261. directory in CDPATH and attempt to change to that drive and directory, until 
  9262. the first match or the end of the CDPATH argument.  This allows you to use 
  9263. CDPATH as a quick way to find commonly used subdirectories which have unique 
  9264. names.  For example, if you are currently in the directory 
  9265. C:\WP\LETTERS\JANUARY and you'd like to change to D:\SOFTWARE\UTIL, you could 
  9266. enter the command: 
  9267.  
  9268.         [c:\wp\letters\january] cdd d:\software\util
  9269.  
  9270. However, if the D:\SOFTWARE directory is listed in your CDPATH variable, and is 
  9271. the first directory in the list with a UTIL subdirectory, you can simply enter 
  9272. the command 
  9273.  
  9274.         [c:\wp\letters\january] cdd util
  9275.  
  9276. to change to D:\SOFTWARE\UTIL. 
  9277.  
  9278. You can create CDPATH with the SET command.  For example, if you want the 
  9279. directory change commands to search the C:\DATA directory, the D:\SOFTWARE 
  9280. directory, and the root directory of drive E:\ for the subdirectories that you 
  9281. name, you should create CDPATH with this command: 
  9282.  
  9283.         [c:\] set cdpath=c:\data;d:\software;e:\
  9284.  
  9285.  
  9286. ΓòÉΓòÉΓòÉ 7.2. CMDLINE ΓòÉΓòÉΓòÉ
  9287.  
  9288. CMDLINE is the fully expanded text of the currently executing command line. 
  9289. CMDLINE is set just before invoking any .COM, .EXE, .BTM, or .CMD file.  If a 
  9290. command line is prefaced with an "@" to prevent echoing, it will not be put in 
  9291. CMDLINE, and any previous CMDLINE variable will be removed from the 
  9292. environment. 
  9293.  
  9294.  
  9295. ΓòÉΓòÉΓòÉ 7.3. COLORDIR ΓòÉΓòÉΓòÉ
  9296.  
  9297. COLORDIR controls directory display colors used by DIR.  See Color-Coded 
  9298. Directories for a complete description of the format of this variable. 
  9299.  
  9300.  
  9301. ΓòÉΓòÉΓòÉ 7.4. COMSPEC ΓòÉΓòÉΓòÉ
  9302.  
  9303. COMSPEC contains the full path and name of the character-mode command 
  9304. processor.  Take Command uses it to start character-mode OS/2 sessions. 
  9305.  
  9306.  
  9307. ΓòÉΓòÉΓòÉ 7.5. PATH (variable) ΓòÉΓòÉΓòÉ
  9308.  
  9309. PATH is a list of directories that Take Command will search for executable 
  9310. files that aren't in the current directory.  PATH may also be used by some 
  9311. application programs to find their own files.  See the PATH command for a full 
  9312. description of this variable. 
  9313.  
  9314.  
  9315. ΓòÉΓòÉΓòÉ 7.6. PROMPT (variable) ΓòÉΓòÉΓòÉ
  9316.  
  9317. PROMPT defines the command-line prompt.  It can be set or changed with the 
  9318. PROMPT command. 
  9319.  
  9320.  
  9321. ΓòÉΓòÉΓòÉ 8. Internal Variables ΓòÉΓòÉΓòÉ
  9322.  
  9323. Internal variables are special variables built into Take Command to provide 
  9324. information about your system.  They are not actually stored in the 
  9325. environment, but can be used in commands, aliases, and batch files just like 
  9326. any environment variable.  The values of these variables are stored internally 
  9327. in Take Command, and cannot be changed with the SET, UNSET, or ESET command. 
  9328. However, you can override any of these variables by defining a new variable 
  9329. with the same name. 
  9330.  
  9331. The list below gives a one-line description of each variable, and a 
  9332. cross-reference which selects a short help topic on that variable.  Most of the 
  9333. variables are simple enough that the one-line description is sufficient. 
  9334. However, for those variables marked with an asterisk [*], the cross-reference 
  9335. topic contains some additional information you may wish to review.  You can 
  9336. also obtain help on any variable with a HELP variable name command at the 
  9337. prompt (this is why each variable has its own topic, in addition to its 
  9338. appearance in the list below). 
  9339.  
  9340. See the discussion after the variable list for some additional information, and 
  9341. examples of how these variables can be used. 
  9342.  
  9343. The variables are: 
  9344.  
  9345. Hardware status 
  9346.  
  9347.         _CPU            CPU type (86, 186, 200, 386, 486, 586) 
  9348.         _NDP            Coprocessor type (0, 87, 287, 387) 
  9349.  
  9350.  Operating system and software status 
  9351.  
  9352.         _ANSI           ANSI status (always 1) 
  9353.         _BOOT           Boot drive letter, without a colon 
  9354.         _CI             Current cursor shape in insert mode 
  9355.         _CO             Current cursor shape in overstrike mode 
  9356.         _CODEPAGE       Current code page number 
  9357.         _COUNTRY        Current country code 
  9358.         _DOS            * Operating system (OS2, PM, DOS, etc.) 
  9359.         _DOSVER         * Operating system version (2.1, 3.0, etc.) 
  9360.         _KBHIT          Keystroke waiting in buffer (0 or 1) 
  9361.         _MOUSE          Mouse driver flag (always 1) 
  9362.  
  9363.  Command processor status 
  9364.  
  9365.         _4VER           Take Command for OS/2 version (1.0, 1.01, etc.) 
  9366.         _ANSI           ANSI status (0 or 1) 
  9367.         _BATCH          Batch nesting level 
  9368.         _BATCHLINE      Current line number in current batch file 
  9369.         _BATCHNAME      Name of current batch file 
  9370.         _DNAME          Name of file used to store file descriptions 
  9371.         _HLOGFILE       Current history log file name 
  9372.         _LOGFILE        Current log file name 
  9373.         _PID            Take Command for OS/2 process ID (numeric) 
  9374.         _PIPE           Whether running in a pipe (0 or 1) 
  9375.         _PPID           Parent process ID (numeric) 
  9376.         _PTYPE          OS/2 process type (PM) 
  9377.         _SHELL          Shell level (0, 1, 2, ...) 
  9378.         _SID            Current OS/2 session ID 
  9379.         _TRANSIENT      * Transient shell flag (0 or 1) 
  9380.         _WINTITLE       Current window title 
  9381.  
  9382.  Screen and color 
  9383.  
  9384.         _BG             Background color at cursor position 
  9385.         _COLUMN         Current cursor column 
  9386.         _COLUMNS        Screen width 
  9387.         _FG             Foreground color at cursor position 
  9388.         _ROW            Current cursor row 
  9389.         _ROWS           Screen height 
  9390.  
  9391.  Drives and directories 
  9392.  
  9393.         _CWD            Current drive and directory (d:\path) 
  9394.         _CWDS           Current drive and directory with trailing \ (d:\path\) 
  9395.         _CWP            Current directory (\path) 
  9396.         _CWPS           Current directory with trailing \ (\path\) 
  9397.         _DISK           Current drive (C, D, etc.) 
  9398.         _LASTDISK       Last possible drive (E, F, etc.) 
  9399.  
  9400.  Dates and times 
  9401.  
  9402.         _DATE           * Current date (mm-dd-yy) 
  9403.         _DAY            Day of the month (1 - 31) 
  9404.         _DOW            Day of the week (Mon, Tue, Wed, etc.) 
  9405.         _DOY            Day of the year (1 - 366) 
  9406.         _HOUR           Hour (0 - 23) 
  9407.         _MINUTE         Minute (0 - 59) 
  9408.         _MONTH          Month of the year (1 - 12) 
  9409.         _SECOND         Second (0 - 59) 
  9410.         _TIME           * Current time (hh:mm:ss) 
  9411.         _YEAR           Year (1980 - 2099) 
  9412.  
  9413.  Error codes 
  9414.  
  9415.         ?               * Exit code, last external program 
  9416.         _?              * Exit code, last internal command 
  9417.         _SYSERR         * Last OS/2 error code 
  9418.  
  9419.  Compatibility 
  9420.  
  9421.         =               * Substitutes escape character 
  9422.         +               * Substitutes command separator 
  9423.  
  9424.  Examples 
  9425.  
  9426.  You can use these variables in a wide variety of ways depending on your needs. 
  9427.  Here are just a couple of examples. 
  9428.  
  9429.  Store the current date and time in a file, then save the output of a DIR 
  9430.  command in the same file: 
  9431.  
  9432.           echo Directory as of %_date %_time > dirsave
  9433.           dir >> dirsave
  9434.  
  9435.  Call another batch file if today is Monday: 
  9436.  
  9437.           if "%_DOW" == "Mon" call c:\cleanup\weekly.bat
  9438.  
  9439.  
  9440. ΓòÉΓòÉΓòÉ 8.1. ┬á? - Exit code, last external program ΓòÉΓòÉΓòÉ
  9441.  
  9442. ? contains the exit code of the last external command.  Many programs return a 
  9443. "0" to indicate success and a non-zero value to signal an error.  However, not 
  9444. all programs return an exit code.  If no explicit exit code is returned, the 
  9445. value of %? is undefined. 
  9446.  
  9447.  
  9448. ΓòÉΓòÉΓòÉ 8.2. _? - Exit code, last internal command ΓòÉΓòÉΓòÉ
  9449.  
  9450. _? contains the exit code of the last internal command.  It is set to "0" if 
  9451. the command was successful, "1" if a usage error occurred, "2" if another 
  9452. command processor error or an operating system error occurred, or "3" if the 
  9453. command was interrupted by Ctrl-C or Ctrl-Break.  You must use or save this 
  9454. value immediately, because it is set by every internal command. 
  9455.  
  9456.  
  9457. ΓòÉΓòÉΓòÉ 8.3. = - Substitutes escape character ΓòÉΓòÉΓòÉ
  9458.  
  9459. = returns the current escape character.  Use this variable, instead of the 
  9460. actual escape character, if you want your batch files and aliases to work 
  9461. regardless of how the escape character is defined.  For example, if the escape 
  9462. character is a caret [^] (the default in Take Command for OS/2) both of the 
  9463. commands below will send a form feed to the printer.  However, if the escape 
  9464. character has been changed,  the first command will send the string "^f" to the 
  9465. printer, while the second command will continue to work as intended. 
  9466.  
  9467.         echos ^f > prn
  9468.         echos %=f > prn
  9469.  
  9470.  
  9471. ΓòÉΓòÉΓòÉ 8.4. + - Substitutes command separator ΓòÉΓòÉΓòÉ
  9472.  
  9473. + returns the current command separator.  Use this variable, instead of the 
  9474. actual command separator, if you want your batch files and aliases to work 
  9475. regardless of how the command separator is defined.  For example, if the 
  9476. command separator is an ampersand [&] (the default in Take Command for OS/2) 
  9477. both of the commands below will display "Hello" on one line and "world" on the 
  9478. next. However, if the command separator has been changed the first command will 
  9479. display "Hello & echo world", while the second command will continue to work as 
  9480. intended. 
  9481.  
  9482.         echo Hello & echo world
  9483.         echo Hello %+ echo world
  9484.  
  9485.  
  9486. ΓòÉΓòÉΓòÉ 8.5. _4VER - Take Command for OS/2 version (1.0, 1.01, etc.) ΓòÉΓòÉΓòÉ
  9487.  
  9488. _4VER is the current Take Command for OS/2 version (for example, "1.0"). The 
  9489. version number is in decimal and uses the appropriate decimal separator for 
  9490. your country (to allow numeric comparisons with the IF and IFF) 
  9491.  
  9492.  
  9493. ΓòÉΓòÉΓòÉ 8.6. _ANSI - ANSI status ΓòÉΓòÉΓòÉ
  9494.  
  9495. _ANSI returns "1" if Take Command's ANSI support is enabled, or "0" if it is 
  9496. disabled.  For more details on ANSI support see SETDOS /A, the ANSI directive 
  9497. in TCMDOS2.INI, or the ANSI Reference. 
  9498.  
  9499.  
  9500. ΓòÉΓòÉΓòÉ 8.7. _BATCH - Batch nesting level ΓòÉΓòÉΓòÉ
  9501.  
  9502. _BATCH is the current batch nesting level.  It is "0" if no batch file is 
  9503. currently being processed. 
  9504.  
  9505.  
  9506. ΓòÉΓòÉΓòÉ 8.8. _BATCHLINE - Current line number in current batch file ΓòÉΓòÉΓòÉ
  9507.  
  9508. _BATCHLINE is the current line number in the current batch file.  It is "-1" if 
  9509. no batch file is currently being processed. 
  9510.  
  9511.  
  9512. ΓòÉΓòÉΓòÉ 8.9. _BATCHNAME - Name of current batch file ΓòÉΓòÉΓòÉ
  9513.  
  9514. _BATCHNAME is the full pathname of the current batch file.  It is an empty 
  9515. string if no batch file is currently being processed. 
  9516.  
  9517.  
  9518. ΓòÉΓòÉΓòÉ 8.10. _BG - Background color at cursor position ΓòÉΓòÉΓòÉ
  9519.  
  9520. _BG is a string containing the first three characters of the screen background 
  9521. color at the current cursor location (for example, "Bla"). 
  9522.  
  9523.  
  9524. ΓòÉΓòÉΓòÉ 8.11. _BOOT - Boot drive letter, without a colon ΓòÉΓòÉΓòÉ
  9525.  
  9526. _BOOT is the boot drive letter, without a colon. 
  9527.  
  9528.  
  9529. ΓòÉΓòÉΓòÉ 8.12. _CI - Current cursor shape in insert mode ΓòÉΓòÉΓòÉ
  9530.  
  9531. _CI is the current shape of the cursor in insert mode, as a percentage. 
  9532.  
  9533.  
  9534. ΓòÉΓòÉΓòÉ 8.13. _CO - Current cursor shape in overstrike mode ΓòÉΓòÉΓòÉ
  9535.  
  9536. _CO is the current shape of the cursor in overstrike mode, as a percentage. 
  9537.  
  9538.  
  9539. ΓòÉΓòÉΓòÉ 8.14. _CODEPAGE - Current code page number ΓòÉΓòÉΓòÉ
  9540.  
  9541. _CODEPAGE is the current code page number (see CHCP). 
  9542.  
  9543.  
  9544. ΓòÉΓòÉΓòÉ 8.15. _COLUMN - Current cursor column ΓòÉΓòÉΓòÉ
  9545.  
  9546. _COLUMN is the current cursor column (for example, "0" for the left side of the 
  9547. screen). 
  9548.  
  9549.  
  9550. ΓòÉΓòÉΓòÉ 8.16. _COLUMNS - Screen width ΓòÉΓòÉΓòÉ
  9551.  
  9552. _COLUMNS is the current number of screen columns (for example, "80"). 
  9553.  
  9554.  
  9555. ΓòÉΓòÉΓòÉ 8.17. _COUNTRY - Current country code ΓòÉΓòÉΓòÉ
  9556.  
  9557. _COUNTRY is the current country code. 
  9558.  
  9559.  
  9560. ΓòÉΓòÉΓòÉ 8.18. _CPU - CPU type (86, 186, 200, 386, 486, 586) ΓòÉΓòÉΓòÉ
  9561.  
  9562. _CPU is the CPU type: 
  9563.  
  9564.         386     i386 
  9565.         486     i486 
  9566.         586     Pentium 
  9567.  
  9568.  
  9569. ΓòÉΓòÉΓòÉ 8.19. _CWD - Current drive and directory (d:\path) ΓòÉΓòÉΓòÉ
  9570.  
  9571. _CWD is the current working directory in the format d:\pathname. 
  9572.  
  9573.  
  9574. ΓòÉΓòÉΓòÉ 8.20. _CWDS - Current drive and directory with trailing backslash (d:\path\) ΓòÉΓòÉΓòÉ
  9575.  
  9576. _CWDS has the same value as CWD, except it ends the pathname with a backslash 
  9577. [\]. 
  9578.  
  9579.  
  9580. ΓòÉΓòÉΓòÉ 8.21. _CWP - Current directory (\path) ΓòÉΓòÉΓòÉ
  9581.  
  9582. _CWP is the current working directory in the format \pathname. 
  9583.  
  9584.  
  9585. ΓòÉΓòÉΓòÉ 8.22. _CWPS - Current directory with trailing backslash (\path\) ΓòÉΓòÉΓòÉ
  9586.  
  9587. _CWPS has the same value as CWP, except it ends the pathname with a backslash 
  9588. [\]. 
  9589.  
  9590.  
  9591. ΓòÉΓòÉΓòÉ 8.23. _DATE - Current date (mm-dd-yy) ΓòÉΓòÉΓòÉ
  9592.  
  9593. _DATE contains the current system date, in the format mm-dd-yy (U.S.), dd-mm-yy 
  9594. (Europe), or yy-mm-dd (Japan). 
  9595.  
  9596.  
  9597. ΓòÉΓòÉΓòÉ 8.24. _DAY - Day of the month (1 - 31) ΓòÉΓòÉΓòÉ
  9598.  
  9599. _DAY is the day of the month (1 to 31). 
  9600.  
  9601.  
  9602. ΓòÉΓòÉΓòÉ 8.25. _DISK - Current drive (C, D, etc.) ΓòÉΓòÉΓòÉ
  9603.  
  9604. _DISK is the current disk drive, without a colon (for example, "C"). 
  9605.  
  9606.  
  9607. ΓòÉΓòÉΓòÉ 8.26. _DNAME - Name of file used to store file descriptions ΓòÉΓòÉΓòÉ
  9608.  
  9609. _DNAME is the name of the file used to store file descriptions.  It can be 
  9610. changed with the DescriptionName directive in TCMDOS2.INI or the SETDOS /D 
  9611. command. 
  9612.  
  9613.  
  9614. ΓòÉΓòÉΓòÉ 8.27. _DOS - Operating system (OS2, PM, DOS, etc.) ΓòÉΓòÉΓòÉ
  9615.  
  9616. _DOS is the operating system and command processor type.  Each JP Software\ 
  9617. command processor returns a different value, as follows: 
  9618.  
  9619.         Product                     Returns 
  9620.  
  9621.         Take Command for OS/2       "PM" (for OS/2 Presentation Manager) 
  9622.         4DOS                        "DOS" 
  9623.         4OS2                        "OS2" 
  9624.         4DOS/NT                     "NT" 
  9625.         Take Command/16             "WIN" 
  9626.         Take Command/32             "WIN95" (under Windows 95) or "WIN32" 
  9627.                                     (under Windows NT) 
  9628.  
  9629.  This variable is useful if you have batch files running in more than one 
  9630.  environment, and need to take different actions depending on the underlying 
  9631.  operating environment. 
  9632.  
  9633.  
  9634. ΓòÉΓòÉΓòÉ 8.28. _DOSVER - Operating system version (2.1, 3.0, etc.) ΓòÉΓòÉΓòÉ
  9635.  
  9636. _DOSVER is the current operating system version (for example, "3.0").  The 
  9637. version number is in decimal and uses the appropriate decimal separator for 
  9638. your country (to allow numeric comparisons with the IF and IFF commands.) 
  9639.  
  9640.  
  9641. ΓòÉΓòÉΓòÉ 8.29. _DOW - Day of the week (Mon, Tue, Wed, etc.) ΓòÉΓòÉΓòÉ
  9642.  
  9643. _DOW is the first three characters of the current day of the week ("Mon", 
  9644. "Tue", "Wed", etc.). 
  9645.  
  9646.  
  9647. ΓòÉΓòÉΓòÉ 8.30. _DOY - Day of the year (1 - 366) ΓòÉΓòÉΓòÉ
  9648.  
  9649. _DOY is the day of the year (1 to 366). 
  9650.  
  9651.  
  9652. ΓòÉΓòÉΓòÉ 8.31. _FG - Foreground color at cursor position ΓòÉΓòÉΓòÉ
  9653.  
  9654. _FG is a string containing the first three letters of the screen foreground 
  9655. color at the current cursor position (for example, "Whi"). 
  9656.  
  9657.  
  9658. ΓòÉΓòÉΓòÉ 8.32. _HLOGFILE - Current history log file name ΓòÉΓòÉΓòÉ
  9659.  
  9660. _HLOGFILE  returns the name of the current history log file (or an empty string 
  9661. if LOG /H is OFF). 
  9662.  
  9663.  
  9664. ΓòÉΓòÉΓòÉ 8.33. _HOUR - Hour (0 - 23) ΓòÉΓòÉΓòÉ
  9665.  
  9666. _HOUR is the current hour (0 - 23). 
  9667.  
  9668.  
  9669. ΓòÉΓòÉΓòÉ 8.34. _KBHIT - Keystroke waiting in buffer (0 or 1) ΓòÉΓòÉΓòÉ
  9670.  
  9671. _KBHIT returns 1 if one or more keystrokes are waiting in the keyboard buffer, 
  9672. or 0 if the keyboard buffer is empty. 
  9673.  
  9674.  
  9675. ΓòÉΓòÉΓòÉ 8.35. _LASTDISK - Last possible drive (E, F, etc.) ΓòÉΓòÉΓòÉ
  9676.  
  9677. _LASTDISK is the last valid drive letter, without a colon. 
  9678.  
  9679.  
  9680. ΓòÉΓòÉΓòÉ 8.36. _LOGFILE - Current log file name ΓòÉΓòÉΓòÉ
  9681.  
  9682. _LOGFILE  returns the name of the current log file (or an empty string if LOG 
  9683. is OFF). 
  9684.  
  9685.  
  9686. ΓòÉΓòÉΓòÉ 8.37. _MINUTE - Minute (0 - 59) ΓòÉΓòÉΓòÉ
  9687.  
  9688. _MINUTE is the current minute (0 - 59). 
  9689.  
  9690.  
  9691. ΓòÉΓòÉΓòÉ 8.38. _MONTH - Month of the year (1 - 12) ΓòÉΓòÉΓòÉ
  9692.  
  9693. _MONTH is the month of the year (1 to 12). 
  9694.  
  9695.  
  9696. ΓòÉΓòÉΓòÉ 8.39. _MOUSE - Mouse driver flag (always 1 in Take Command for OS/2) ΓòÉΓòÉΓòÉ
  9697.  
  9698. _MOUSE always returns "1" in Take Command for OS/2. 
  9699.  
  9700.  
  9701. ΓòÉΓòÉΓòÉ 8.40. _NDP - Coprocessor type (0, 87, 287, 387) ΓòÉΓòÉΓòÉ
  9702.  
  9703. _NDP is the coprocessor type: 
  9704.  
  9705.         0       no coprocessor is installed 
  9706.         387     80387, 80486DX, or Pentium 
  9707.  
  9708.  
  9709. ΓòÉΓòÉΓòÉ 8.41. _PID - Take Command for OS/2 process ID (numeric) ΓòÉΓòÉΓòÉ
  9710.  
  9711. _PID is the current process ID number. 
  9712.  
  9713.  
  9714. ΓòÉΓòÉΓòÉ 8.42. _PIPE - Whether running in a pipe (0 or 1) ΓòÉΓòÉΓòÉ
  9715.  
  9716. _PIPE returns 1 if the current process is running inside a pipe or 0 otherwise. 
  9717.  
  9718.  
  9719. ΓòÉΓòÉΓòÉ 8.43. _PPID - Parent process ID (numeric) ΓòÉΓòÉΓòÉ
  9720.  
  9721. _PPID is the process ID number of the parent process. 
  9722.  
  9723.  
  9724. ΓòÉΓòÉΓòÉ 8.44. _PTYPE - OS/2 process type (PM) ΓòÉΓòÉΓòÉ
  9725.  
  9726. _PTYPE is the current OS/2 process type.  It is included for compatibility with 
  9727. 4OS2, but will always return PM in Take Command for OS/2. 
  9728.  
  9729.  
  9730. ΓòÉΓòÉΓòÉ 8.45. _ROW - Current cursor row ΓòÉΓòÉΓòÉ
  9731.  
  9732. _ROW is the current cursor row (for example, "0" for the top of the screen). 
  9733.  
  9734.  
  9735. ΓòÉΓòÉΓòÉ 8.46. _ROWS - Screen height ΓòÉΓòÉΓòÉ
  9736.  
  9737. _ROWS is the current number of screen rows (for example, "25"). 
  9738.  
  9739.  
  9740. ΓòÉΓòÉΓòÉ 8.47. _SECOND - Second (0 - 59) ΓòÉΓòÉΓòÉ
  9741.  
  9742. _SECOND is the current second (0 - 59). 
  9743.  
  9744.  
  9745. ΓòÉΓòÉΓòÉ 8.48. _SHELL - Shell level (0, 1, 2, ...) ΓòÉΓòÉΓòÉ
  9746.  
  9747. _SHELL is the current shell nesting level.  The primary shell is level "0", and 
  9748. each subsequent secondary shell increments the level by 1. 
  9749.  
  9750.  
  9751. ΓòÉΓòÉΓòÉ 8.49. _SID - Current OS/2 session ID ΓòÉΓòÉΓòÉ
  9752.  
  9753. _SID is the session ID number. 
  9754.  
  9755.  
  9756. ΓòÉΓòÉΓòÉ 8.50. _SYSERR - Last OS/2 error code ΓòÉΓòÉΓòÉ
  9757.  
  9758. _SYSERR is the error code of the last operating system error. You will need a 
  9759. technical or programmer's manual to understand these error values. 
  9760.  
  9761.  
  9762. ΓòÉΓòÉΓòÉ 8.51. _TIME - Current time (hh:mm:ss) ΓòÉΓòÉΓòÉ
  9763.  
  9764. _TIME contains the current system time in the format hh:mm:ss. The separator 
  9765. character may vary depending upon your country information. 
  9766.  
  9767.  
  9768. ΓòÉΓòÉΓòÉ 8.52. _TRANSIENT - Transient shell flag (0 or 1) ΓòÉΓòÉΓòÉ
  9769.  
  9770. _TRANSIENT is "1" if the current shell is transient (started with a /C, see 
  9771. Startup Options for details), or "0" otherwise. 
  9772.  
  9773.  
  9774. ΓòÉΓòÉΓòÉ 8.53. _WINTITLE - Current window title ΓòÉΓòÉΓòÉ
  9775.  
  9776. _WINTITLE returns the title of the current window. 
  9777.  
  9778.  
  9779. ΓòÉΓòÉΓòÉ 8.54. _YEAR - Year (1980 - 2099) ΓòÉΓòÉΓòÉ
  9780.  
  9781. _YEAR is the current year (1980 to 2099). 
  9782.  
  9783.  
  9784. ΓòÉΓòÉΓòÉ 9. Variable Functions ΓòÉΓòÉΓòÉ
  9785.  
  9786. Variable Functions 
  9787.  
  9788. Variable functions are like internal variables, but they take one or more 
  9789. arguments (which can be environment variables or even other variable functions) 
  9790. and they return a value. 
  9791.  
  9792. The list below gives a one-line description of each function, and a 
  9793. cross-reference which selects a separate help topic on that function.  A few of 
  9794. the variables are simple enough that the one-line description is sufficient, 
  9795. but in most cases you should check for any additional information in the 
  9796. cross-referenced explanation if you are not already familiar with a function. 
  9797. You can also obtain help on any function with a HELP @functionname command at 
  9798. the prompt. 
  9799.  
  9800. See the discussion after the function list for additional information and 
  9801. examples. 
  9802.  
  9803. The variable functions are: 
  9804.  
  9805. System status 
  9806.  
  9807.         @DOSMEM[b|k|m]                      Size of largest free memory block 
  9808.         @READSCR[row,col,len]               Read characters from the screen 
  9809.  
  9810.  Drives and devices 
  9811.  
  9812.         @CDROM[d:]                          CD-ROM drive detection (0 or 1) 
  9813.         @DEVICE[name]                       Character device detection 
  9814.         @DISKFREE[d:,b|k|m]                 Free disk space 
  9815.         @DISKTOTAL[d:,b|k|m]                Total disk space 
  9816.         @DISKUSED[d:,b|k|m]                 Used disk space 
  9817.         @FSTYPE[d:]                         File system type (FAT, HPFS, CDFS, 
  9818.                                             etc.) 
  9819.         @LABEL[d:]                          Volume label 
  9820.         @READY[d:]                          Drive ready status (0 or 1) 
  9821.         @REMOTE[d:]                         Remote (network) drive detection (0 
  9822.                                             or 1) 
  9823.         @REMOVABLE[d:]                      Removable drive detection (0 or 1) 
  9824.  
  9825.  Files 
  9826.  
  9827.         @ATTRIB[filename,[nrhsda]]          File attribute test (0 or 1) 
  9828.         @DESCRIPT[filename]                 File description 
  9829.         @EXETYPE[filename]                  Executable file type (DOS, PM, WIN, 
  9830.                                             etc.) 
  9831.         @FILEAGE[filename]                  File age (date and time) 
  9832.         @FILECLOSE[n]                       Close a file 
  9833.         @FILEDATE[filename]                 File date 
  9834.         @FILEOPEN[filename,mode]            Open a file 
  9835.         @FILEREAD[n [,length]]              Read next line from a file 
  9836.         @FILES[filename [,-nrhsda]]         Count files matching a wildcard 
  9837.         @FILESEEK[n,offset,start]           Move a file pointer to an offset 
  9838.         @FILESEEKL[n,offset,start]          Move a file pointer to a line 
  9839.                                             number 
  9840.         @FILESIZE[filename,b|k|m]           Size of files matching a wildcard 
  9841.         @FILETIME[filename]                 File time 
  9842.         @FILEWRITE[n,text]                  Write next line to a file 
  9843.         @FILEWRITEB[n,length,string]        Write bytes from a string to a file 
  9844.         @FINDCLOSE[filename]                Terminate an @FINDFIRST / @FINDNEXT 
  9845.                                             scan 
  9846.         @FINDFIRST[filename,nrhsda]         Find first matching file 
  9847.         @FINDNEXT[filename,nrhsda]          Find next matching file 
  9848.         @LINE[filename,n]                   Read a random line from a file 
  9849.         @LINES[filename]                    Count lines in a file 
  9850.         @SEARCH[filename]                   Path search 
  9851.         @UNIQUE[d:\path]                    Create file with unique name 
  9852.  
  9853.  File names 
  9854.  
  9855.         @EXT[filename]                      File extension 
  9856.         @FILENAME[filename]                 File name and extension 
  9857.         @FULL[filename]                     Full file name with path 
  9858.         @NAME[filename]                     File name without path or extension 
  9859.         @PATH[filename]                     File path without name 
  9860.  
  9861.  Strings and characters 
  9862.  
  9863.         @ASCII[c]                           Numeric ASCII value for a character 
  9864.         @CHAR[n]                            Character value for numeric ASCII 
  9865.         @FORMAT[[-][x][.y],string]          Formats (justifies) a string 
  9866.         @INDEX[string1,string2]             Position of one string in another 
  9867.         @INSTR[start,length,string]         Extract a substring 
  9868.         @LEN[string]                        Length of a string 
  9869.         @LOWER[string]                      Convert string to lower case 
  9870.         @REPEAT[c,n]                        Repeat a character 
  9871.         @SUBSTR[string,start,length]        Extract a substring 
  9872.         @TRIM[string]                       Remove blanks from a string 
  9873.         @UPPER[string]                      Convert string to upper case 
  9874.         @WORD[["sep",]n,string]             Extract a word from a string 
  9875.         @WORDS[["sep",]string]              Counts number of words in a string 
  9876.  
  9877.  Numbers and arithmetic 
  9878.  
  9879.         @COMMA[n]                           Inserts commas in a number 
  9880.         @DEC[%var]                          Decremented value of a variable 
  9881.         @EVAL[expression]                   Arithmetic calculations 
  9882.         @INC[%var]                          Incremented value of a variable 
  9883.         @INT[n]                             Integer part of a number 
  9884.         @NUMERIC[string]                    Test if a string is numeric 
  9885.         @RANDOM[min,max]                    Generate a random integer 
  9886.  
  9887.  Dates and times 
  9888.  
  9889.         @DATE[mm-dd-yy]                     Convert date to number of days 
  9890.         @MAKEAGE[n]                         Convert date/time to file date/time 
  9891.         @MAKEDATE[n]                        Convert number of days to date 
  9892.         @MAKETIME[n]                        Convert number of seconds to time 
  9893.         @TIME[hh:mm:ss]                     Convert time to number of seconds 
  9894.         @TIMER[n]                           Elapsed time of specified timer 
  9895.  
  9896.  Utility 
  9897.  
  9898.         @ALIAS[name]                        Value of an alias 
  9899.         @IF[condition,true,false]           Evaluates a test condition 
  9900.         @EXEC[command]                      Execute a command 
  9901.         @REXX[expr]                         Execute a REXX expression 
  9902.         @SELECT[file,t,l,b,r,title]         Menu selection 
  9903.  
  9904.  Like all environment variables, these variable functions must be preceded by a 
  9905.  percent sign (%@EVAL, %@LEN, etc.).  All variable functions must have square 
  9906.  brackets enclosing their argument(s).  The argument(s) to a variable function 
  9907.  cannot exceed 255 characters in length for all arguments taken as a group. 
  9908.  
  9909.  Some variable functions, like @DISKFREE, are shown with "b|k|m" as one of 
  9910.  their arguments.  Those functions return a number of bytes, kilobytes, or 
  9911.  megabytes based on the "b|k|m" argument: 
  9912.  
  9913.         b   return the number of bytes 
  9914.         K   return the number of kilobytes (bytes / 1,024) 
  9915.         k   return the number of thousands of bytes (bytes / 1,000) 
  9916.         M   return the number of megabytes (bytes / 1,048,576) 
  9917.         m   return the number of millions of bytes (bytes / 1,000,000) 
  9918.  
  9919.  You can include commas in the results from a "b|k|m" function by appending a 
  9920.  "c" to the argument.  For example, to add commas to a "b" or number of bytes 
  9921.  result, enter "bc" as the argument. 
  9922.  
  9923.  In variable functions which take a drive letter as an argument, like @DISKFREE 
  9924.  or @READY, the drive letter must be followed by a colon.  The function will 
  9925.  not work properly if you use the drive letter without the colon. 
  9926.  
  9927.  The @FILEREAD, @FILEWRITE, @FILESEEK, and @FILECLOSE functions allow you to 
  9928.  access files based on a file handle.  These functions should only be used with 
  9929.  file handles returned by @FILEOPEN!  If you use them with any other number you 
  9930.  may damage other files opened by Take Command (or by the program which started 
  9931.  Take Command), or hang your system. 
  9932.  
  9933.  Examples 
  9934.  
  9935.  You can use variable functions in a wide variety of ways depending on your 
  9936.  needs.  We've included a few examples below to give you an idea of what's 
  9937.  possible. 
  9938.  
  9939.  To set the prompt to show the amount of free memory (see PROMPT for details on 
  9940.  including variable functions in your prompt): 
  9941.  
  9942.           [c:\] prompt (%%@dosmem[K]K) $p$g
  9943.  
  9944.  Set up a simple command-line calculator.  The calculator is used with a 
  9945.  command like CALC 3 * (4 + 5): 
  9946.  
  9947.           [c:\] alias calc `echo The answer is:  %@eval[%&]`
  9948.  
  9949.  
  9950. ΓòÉΓòÉΓòÉ 9.1. @ALIAS - Value of an alias ΓòÉΓòÉΓòÉ
  9951.  
  9952. @ALIAS[name]  Returns the contents of the specified alias as a string, or a 
  9953. null string if the alias doesn't exist.  When manipulating strings returned by 
  9954. @ALIAS you may need to disable certain special characters with the SETDOS /X 
  9955. command. Otherwise, command separators, redirection characters, and other 
  9956. similar "punctuation" in the alias may be interpreted as part of the current 
  9957. command, rather than part of a simple text string. 
  9958.  
  9959.  
  9960. ΓòÉΓòÉΓòÉ 9.2. @ASCII - Numeric ASCII value for a character ΓòÉΓòÉΓòÉ
  9961.  
  9962. @ASCII[c]:  Returns the numeric value of the specified ASCII character as a 
  9963. string.  For example %@ASCII[A] returns 65.  You can put an escape character 
  9964. [^] before the actual character to process.  This allows quotes and other 
  9965. special characters as the argument (e.g., %@ASCII[^`]). 
  9966.  
  9967.  
  9968. ΓòÉΓòÉΓòÉ 9.3. @ATTRIB - File attribute test (0 or 1) ΓòÉΓòÉΓòÉ
  9969.  
  9970. @ATTRIB[filename[,nrhsda[,p]]]:  Returns a "1" if the specified file has the 
  9971. matching attribute(s); otherwise returns a "0". The attributes are: 
  9972.  
  9973.         N   Normal (no attributes set) 
  9974.         R   Read-only 
  9975.         H   Hidden 
  9976.         S   System 
  9977.         D   Directory 
  9978.         A   Archive 
  9979.  
  9980.  The attributes (other than N) can be combined (for example 
  9981.  %@ATTRIB[MYFILE,HS]).  Normally ATTRIB will only return a "1" if all of the 
  9982.  attributes match. However, if a final ,p is included (for partial match), then 
  9983.  @ATTRIB will return a "1" if any of the attributes match.  For example, 
  9984.  %@ATTRIB[MYFILE,HS,p] will return a "1" if MYFILE has the hidden, system, or 
  9985.  both attributes.  Without ,p the function will return a "1" only if MYFILE has 
  9986.  both attributes. 
  9987.  
  9988.  If you do not specify any attributes, @ATTRIB will return the attributes of 
  9989.  the specified file in the format RHSAD, rather than a "0" or "1".  Attributes 
  9990.  which are not set will be replaced with an underscore.  For example. if 
  9991.  SECURE.DAT has the read-only, hidden, and archive attributes set, 
  9992.  %@ATTRIB[SECURE.DAT] would return "RH_A_" (without the quotes).  If the file 
  9993.  does not exist, @ATTRIB will return an empty string. 
  9994.  
  9995.  
  9996. ΓòÉΓòÉΓòÉ 9.4. @CDROM - CD-ROM drive detection (0 or 1) ΓòÉΓòÉΓòÉ
  9997.  
  9998. @CDROM[d:]:  Returns "1" if the drive is a CD-ROM or "0" otherwise. 
  9999.  
  10000.  
  10001. ΓòÉΓòÉΓòÉ 9.5. @CHAR - Character value for numeric ASCII ΓòÉΓòÉΓòÉ
  10002.  
  10003. @CHAR[n]:  Returns the character corresponding to an ASCII numeric value.  For 
  10004. example %@CHAR[65] returns A. 
  10005.  
  10006.  
  10007. ΓòÉΓòÉΓòÉ 9.6. @COMMA - Inserts commas in a number ΓòÉΓòÉΓòÉ
  10008.  
  10009. @COMMA[n]:  Returns the number with commas (or the appropriate thousands 
  10010. separator for your current country setting) inserted where appropriate. 
  10011.  
  10012.  
  10013. ΓòÉΓòÉΓòÉ 9.7. @DATE - Convert date to number of days ΓòÉΓòÉΓòÉ
  10014.  
  10015. @DATE[mm-dd-yy]:  Returns the number of days since January 1, 1980 for the 
  10016. specified date.  DATE uses the date format and separators mandated by your 
  10017. country code (for example dd.mm.yy in Germany, or yy-mm-dd in Japan). 
  10018.  
  10019.  
  10020. ΓòÉΓòÉΓòÉ 9.8. @DEC - Decremented value of a variable ΓòÉΓòÉΓòÉ
  10021.  
  10022. @DEC[%var]:  Returns the same value as @EVAL[%var - 1].  That is, it retrieves 
  10023. and decrements the value of a variable. The variable itself is not changed; to 
  10024. do so, use a command like this: 
  10025.  
  10026.         set var=%@dec[%var]
  10027.  
  10028.  
  10029. ΓòÉΓòÉΓòÉ 9.9. @DESCRIPT - File description ΓòÉΓòÉΓòÉ
  10030.  
  10031. @DESCRIPT[filename]  Returns the file description for the specified filename 
  10032. (see DESCRIBE). 
  10033.  
  10034.  
  10035. ΓòÉΓòÉΓòÉ 9.10. @DEVICE - Character device detection ΓòÉΓòÉΓòÉ
  10036.  
  10037. @DEVICE[name]:  Returns "1" if the specified name is a character device (such 
  10038. as a printer or serial port), or "0" if not. 
  10039.  
  10040.  
  10041. ΓòÉΓòÉΓòÉ 9.11. @DISKFREE - Free disk space ΓòÉΓòÉΓòÉ
  10042.  
  10043. @DISKFREE[d:,b|k|m]: Returns the amount of free disk space on the specified 
  10044. drive. 
  10045.  
  10046.  
  10047. ΓòÉΓòÉΓòÉ 9.12. @DISKTOTAL - Total disk space ΓòÉΓòÉΓòÉ
  10048.  
  10049. @DISKTOTAL[d:,b|k|m]:  Returns the total disk space on the specified drive. 
  10050.  
  10051.  
  10052. ΓòÉΓòÉΓòÉ 9.13. @DISKUSED - Used disk space ΓòÉΓòÉΓòÉ
  10053.  
  10054. @DISKUSED[d:,b|k|m]:  Returns the amount of disk space in use by files and 
  10055. directories on the specified drive. 
  10056.  
  10057.  
  10058. ΓòÉΓòÉΓòÉ 9.14. @DOSMEM - Size of largest free memory block ΓòÉΓòÉΓòÉ
  10059.  
  10060. @DOSMEM[b|k|m]:  Returns the size of the largest free memory block (either in 
  10061. physical or virtual memory). 
  10062.  
  10063.  
  10064. ΓòÉΓòÉΓòÉ 9.15. @EVAL - Arithmetic calculations ΓòÉΓòÉΓòÉ
  10065.  
  10066. @EVAL[expression]:  Evaluates an arithmetic expression.  @EVAL supports 
  10067. addition (+), subtraction (-), multiplication (*), division (/), integer 
  10068. division (\, returns the integer part of the quotient), modulo (%%), and 
  10069. integer exponentiation (**).  The expression can contain environment variables 
  10070. and other variable functions.  @EVAL also supports parentheses, commas, and 
  10071. decimals.  Parentheses can be nested. @EVAL will strip leading and trailing 
  10072. zeros from the result.  When evaluating expressions, **, *, /, and %% take 
  10073. precedence over + and -. For example, 3 + 4 * 2 will be interpreted as 3 + 8, 
  10074. not as 7 * 2.  To change this order of evaluation, use parentheses to specify 
  10075. the order you want. 
  10076.  
  10077. The maximum precision is 16 digits to the left of the decimal point and 0 to 8 
  10078. digits to the right of the decimal point.  You can alter the default precision 
  10079. with the EvalMax and EvalMin  directives inTCMDOS2.INI, and with the SETDOS /F 
  10080. command. 
  10081.  
  10082. You can alter the precision for a single evaluation with the construct 
  10083. @EVAL[expression=x.y].  The x value specifies the the minimum decimal precision 
  10084. (the minimum number of decimal places displayed); the y value sets the maximum 
  10085. decimal (rounding) precision.  If x is greater than y, it is ignored.  You can 
  10086. specify either or both arguments: @EVAL[3/7=2], @EVAL[3/7=2.4], or 
  10087. @EVAL[3/7=.4]. 
  10088.  
  10089. Also see @DEC and @INC. 
  10090.  
  10091.  
  10092. ΓòÉΓòÉΓòÉ 9.16. @EXEC - Execute a command ΓòÉΓòÉΓòÉ
  10093.  
  10094. @EXEC[command]:  Execute the command and return the numeric exit code.  The 
  10095. command can be an alias, internal command, external command, .BTM file, or .BAT 
  10096. file.  @EXEC is primarily intended for running a program from within the 
  10097. PROMPT.  It is a "back door" entry into command processing and should be used 
  10098. with extreme caution.  Incorrect or recursive use of @EXEC may hang your 
  10099. system. 
  10100.  
  10101.  
  10102. ΓòÉΓòÉΓòÉ 9.17. @EXETYPE - Executable file type (DOS, PM, WIN, etc.) ΓòÉΓòÉΓòÉ
  10103.  
  10104. @EXETYPE[filename]:  Returns the application type as a string: 
  10105.  
  10106.         DOS         DOS .COM, .EXE, or .BAT file 
  10107.         AVIO        OS/2 Character mode, windowed 
  10108.         FS          OS/2 Character mode, full-screen 
  10109.         PM          OS/2 Presentation Manager 
  10110.         WIN         Windows 3 
  10111.         UNKNOWN     Any other file 
  10112.  
  10113.  
  10114. ΓòÉΓòÉΓòÉ 9.18. @EXT - File extension ΓòÉΓòÉΓòÉ
  10115.  
  10116. @EXT[filename]:  Returns the extension from a file name, without a leading 
  10117. period. 
  10118.  
  10119.  
  10120. ΓòÉΓòÉΓòÉ 9.19. @FILEAGE - File age (date and time) ΓòÉΓòÉΓòÉ
  10121.  
  10122. @FILEAGE[filename]:  Returns the date and time of the file as a single numeric 
  10123. value.  The number can be used to compare the relative ages of two or more 
  10124. files. 
  10125.  
  10126.  
  10127. ΓòÉΓòÉΓòÉ 9.20. @FILECLOSE - Close a file ΓòÉΓòÉΓòÉ
  10128.  
  10129. @FILECLOSE[n]:  Closes the file whose handle is "n." You cannot close handles 
  10130. 0, 1 or 2.  Returns "0" if the file closed OK or "-1" if an error occurred.  Be 
  10131. sure to read the cautionary note about file functions under Variable Functions. 
  10132.  
  10133.  
  10134. ΓòÉΓòÉΓòÉ 9.21. @FILEDATE - File date ΓòÉΓòÉΓòÉ
  10135.  
  10136. @FILEDATE[filename]:  Returns the date a file was last modified, in the default 
  10137. country format (mm-dd-yy for the US). 
  10138.  
  10139.  
  10140. ΓòÉΓòÉΓòÉ 9.22. @FILENAME - File name and extension ΓòÉΓòÉΓòÉ
  10141.  
  10142. @FILENAME[filename]:  Returns the name and extension of a file, without a path. 
  10143.  
  10144.  
  10145. ΓòÉΓòÉΓòÉ 9.23. @FILEOPEN - Open a file ΓòÉΓòÉΓòÉ
  10146.  
  10147. @FILEOPEN[filename, read | write | append[,b|t]]:  Opens the file in the 
  10148. specified mode and returns the file handle as an integer.  If you add "b" the 
  10149. file is opened in binary mode;  "t" means text mode, the default.  In binary 
  10150. mode, no special translation of CR/LF pairs is performed.  Returns "-1" if the 
  10151. file cannot be opened. Be sure to read the cautionary note about file functions 
  10152. under Variable Functions. 
  10153.  
  10154. @FILEOPEN can also open named pipes.  The pipe name must begin with \pipe\. 
  10155. @FILEOPEN first tries to open an existing pipe; if that fails it tries to 
  10156. create a new pipe.  Pipes are opened in blocking mode, duplex access, byte-read 
  10157. mode, and inheritable. For more information on named pipes see your OS/2 
  10158. documentation. 
  10159.  
  10160.  
  10161. ΓòÉΓòÉΓòÉ 9.24. @FILEREAD - [,length]] Read next line from a file ΓòÉΓòÉΓòÉ
  10162.  
  10163. @FILEREAD[n[,length]]:  Reads a line or a series of bytes from the file whose 
  10164. handle is "n."  Returns "**EOF**" if you attempt to read past the end of the 
  10165. file.  If length is not given @FILEREAD reads up to the next CR or LF 
  10166. character.  If length is given @FILEREAD reads the specified number of bytes 
  10167. regardless of whether CR or LF characters are found.  Be sure to read the 
  10168. cautionary note about file functions under Variable Functions. 
  10169.  
  10170.  
  10171. ΓòÉΓòÉΓòÉ 9.25. @FILES - Count files matching a wildcard ΓòÉΓòÉΓòÉ
  10172.  
  10173. @FILES[filename [,-nrhsda]]:  Returns the number of files that match the 
  10174. filename specification, which may contain wildcards and include lists.  The 
  10175. filename must refer to a single directory; to check several directories, use 
  10176. @FILES once for each directory, and add the results together with @EVAL. The 
  10177. second argument, if included, defines the attributes of the files that will be 
  10178. included in the search.  Returns an empty string if no files match.  The 
  10179. attributes are: 
  10180.  
  10181.         N   Normal (no attributes set) 
  10182.         R   Read-only 
  10183.         H   Hidden 
  10184.         S   System 
  10185.         D   Directory 
  10186.         A   Archive 
  10187.  
  10188.  The attributes (other than N) can be combined (for example 
  10189.  %@FINDFIRST[MYFILE,HS]).  @FINDFIRST will only find a file if all of the 
  10190.  attributes match.  You can prefix an attribute with "-" to mean "everything 
  10191.  except files with this attribute." 
  10192.  
  10193.  
  10194. ΓòÉΓòÉΓòÉ 9.26. @FILESEEK - Move a file pointer to an offset ΓòÉΓòÉΓòÉ
  10195.  
  10196. @FILESEEK[n,offset,start]:  Moves the file pointer "offset" bytes in the file 
  10197. whose handle is "n".  Returns the new position of the pointer, in bytes from 
  10198. the start of the file.  Set "start" to 0 to seek relative to the beginning of 
  10199. the file, 1 to seek relative to the current file pointer, or 2 to seek relative 
  10200. to the end of the file.  The offset value may be negative (seek backward), 
  10201. positive (seek forward), or zero (return current position, but do not change 
  10202. it).  Be sure to read the cautionary note about file functions under Variable 
  10203. Functions. 
  10204.  
  10205.  
  10206. ΓòÉΓòÉΓòÉ 9.27. @FILESEEKL - Move a file pointer to a line number ΓòÉΓòÉΓòÉ
  10207.  
  10208. @FILESEEKL[n,line]:  Moves the file pointer to the specified line in the file 
  10209. whose handle is "n". Returns the new position of the pointer, in bytes from the 
  10210. start of the file. Be sure to read the cautionary note about file functions 
  10211. under Variable Functions 
  10212.  
  10213.  
  10214. ΓòÉΓòÉΓòÉ 9.28. @FILESIZE - Size of files matching a wildcard ΓòÉΓòÉΓòÉ
  10215.  
  10216. @FILESIZE[filename,b|k|m]:  Returns the size of a file, or "-1" if the file 
  10217. does not exist.  If the filename includes wildcards or an include list, returns 
  10218. the combined size of all matching files. 
  10219.  
  10220.  
  10221. ΓòÉΓòÉΓòÉ 9.29. @FILETIME - File time ΓòÉΓòÉΓòÉ
  10222.  
  10223. @FILETIME[filename]:  Returns the time a file was last modified, in hh:mm 
  10224. format. 
  10225.  
  10226.  
  10227. ΓòÉΓòÉΓòÉ 9.30. @FILEWRITE - Write next line to a file ΓòÉΓòÉΓòÉ
  10228.  
  10229. @FILEWRITE[n,text]:  Writes a line to the file whose handle is "n".  Returns 
  10230. the number of bytes written, or "-1" if an error occurred.  Be sure to read the 
  10231. cautionary note about file functions under Variable Functions. 
  10232.  
  10233.  
  10234. ΓòÉΓòÉΓòÉ 9.31. @FILEWRITEB - Write bytes from a string to a file ΓòÉΓòÉΓòÉ
  10235.  
  10236. @FILEWRITEB[n,length,string]:  Writes the specified number of bytes from the 
  10237. string to the file whose handle is "n". Returns the number of bytes written, or 
  10238. "-1" if an error occurred.  Be sure to read the cautionary note about file 
  10239. functions under Variable Functions. 
  10240.  
  10241.  
  10242. ΓòÉΓòÉΓòÉ 9.32. @FINDCLOSE - Terminate a find first / find next scan ΓòÉΓòÉΓòÉ
  10243.  
  10244. @FINDCLOSE[filename]:  Signals the end of a @FINDFIRST / @FINDNEXT sequence. 
  10245. You must use this function to release the directory search handle. 
  10246.  
  10247.  
  10248. ΓòÉΓòÉΓòÉ 9.33. @FINDFIRST - Find first matching file ΓòÉΓòÉΓòÉ
  10249.  
  10250. @FINDFIRST[filename [,[-]nrhsda]]:  Returns the name of the first file that 
  10251. matches the filename, which may include wildcards and/or an include list.  The 
  10252. second argument, if included, defines the attributes of the files that will be 
  10253. included in the search. Returns an empty string if no files match.  The 
  10254. attributes are: 
  10255.  
  10256.         N   Normal (no attributes set) 
  10257.         R   Read-only 
  10258.         H   Hidden 
  10259.         S   System 
  10260.         D   Directory 
  10261.         A   Archive 
  10262.  
  10263.  The attributes (other than N) can be combined (for example 
  10264.  %@FINDFIRST[MYFILE,HS]).  @FINDFIRST will only find a file if all of the 
  10265.  attributes match.  You can prefix an attribute with "-" to mean "everything 
  10266.  except files with this attribute." 
  10267.  
  10268.  After @FINDFIRST or the last @FINDNEXT, you must use @FINDCLOSE to avoid 
  10269.  running out of directory search handles. 
  10270.  
  10271.  
  10272. ΓòÉΓòÉΓòÉ 9.34. @FINDNEXT - Find next matching file ΓòÉΓòÉΓòÉ
  10273.  
  10274. @FINDNEXT[[filename [,[-]nrhsda]]]:  Returns the name of the next file that 
  10275. matches the filename(s) in the previous @FINDFIRST call. The second argument, 
  10276. if included, defines the attributes of the files that will be included in the 
  10277. search (see @FINDFIRST for details). Returns an empty string when no more files 
  10278. match.  @FINDNEXT should only be used after a successful call to @FINDFIRST. 
  10279. You do not need to include the filename parameter, because it must be the same 
  10280. as the previous @FINDFIRST call, unless you also want to specify file 
  10281. attributes for @FINDNEXT. 
  10282.  
  10283. After the last @FINDNEXT, you must use @FINDCLOSE to avoid running out of 
  10284. directory search handles. 
  10285.  
  10286.  
  10287. ΓòÉΓòÉΓòÉ 9.35. @FORMAT - Formats (justifies) a string ΓòÉΓòÉΓòÉ
  10288.  
  10289. @FORMAT[[-][x][.y],string]:  Reformats a string, truncating it or padding it 
  10290. with spaces as necessary.  If you use the minus [-], the string is 
  10291. left-justified; otherwise, it is right-justified.  The x value is the minimum 
  10292. number of characters in the result.  The y value is the maximum number of 
  10293. characters in the result.  You can combine the options as necessary.  For 
  10294. example, Echo %@format[7,Hello] displays "Hello" while Echo %@format[.3,Hello] 
  10295. displays "Hel". 
  10296.  
  10297.  
  10298. ΓòÉΓòÉΓòÉ 9.36. @FSTYPE - File system type (FAT, HPFS, CDFS, etc.) ΓòÉΓòÉΓòÉ
  10299.  
  10300. @FSTYPE[d:]:  Returns the file system type for the specified drive.  @FSTYPE 
  10301. will return "FAT" for a DOS-compatible drive with a file allocation table, 
  10302. "HPFS" for a drive that uses the OS/2 high performance file system, or "CDFS" 
  10303. for a CD-ROM drive.  It may return other values if additional file systems have 
  10304. been installed. 
  10305.  
  10306.  
  10307. ΓòÉΓòÉΓòÉ 9.37. @FULL - Full file name with path ΓòÉΓòÉΓòÉ
  10308.  
  10309. @FULL[filename]:  Returns the fully qualified path name of a file. 
  10310.  
  10311.  
  10312. ΓòÉΓòÉΓòÉ 9.38. @IF - Evaluates a test condition ΓòÉΓòÉΓòÉ
  10313.  
  10314. @IF[condition,true,false]:  Evaluates the condition and returns a string based 
  10315. on the result.  The condition can include any of the tests allowed in the IF 
  10316. command. If the condition is true, @IF returns the first result string; if it 
  10317. is false, @IF returns the second string.  For example, %IF[2==2,Correct!,Oops!] 
  10318. returns "Correct!" 
  10319.  
  10320.  
  10321. ΓòÉΓòÉΓòÉ 9.39. @INC - Incremented value of a variable ΓòÉΓòÉΓòÉ
  10322.  
  10323. @INC[%var]:  Returns the same value as %@EVAL[%var + 1].  That is, it retrieves 
  10324. and increments the value of a variable. The variable itself is not changed; to 
  10325. do so, use a command like this: 
  10326.  
  10327.         set var=%@inc[%var]
  10328.  
  10329.  
  10330. ΓòÉΓòÉΓòÉ 9.40. @INDEX - Position of one string in another ΓòÉΓòÉΓòÉ
  10331.  
  10332. @INDEX[string1,string2]  Returns the position of string2 within string1, or 
  10333. "-1" if string2 is not found.  The first position in string1 is numbered 0. 
  10334.  
  10335.  
  10336. ΓòÉΓòÉΓòÉ 9.41. @INSTR - Extract a substring ΓòÉΓòÉΓòÉ
  10337.  
  10338. @INSTR[start, length, string]:  The same as @SUBSTR.  However, the string is at 
  10339. the end of the @INSTR argument list, so that commas in the string will not be 
  10340. confused with commas separating the arguments. 
  10341.  
  10342.  
  10343. ΓòÉΓòÉΓòÉ 9.42. @INT - Integer part of a number ΓòÉΓòÉΓòÉ
  10344.  
  10345. @INT[n]:  Returns the integer part of the number n. 
  10346.  
  10347.  
  10348. ΓòÉΓòÉΓòÉ 9.43. @LABEL - Volume label ΓòÉΓòÉΓòÉ
  10349.  
  10350. @LABEL[d:]:  Returns the volume label of the specified disk drive. 
  10351.  
  10352.  
  10353. ΓòÉΓòÉΓòÉ 9.44. @LEN - Length of a string ΓòÉΓòÉΓòÉ
  10354.  
  10355. @LEN[string]:  Returns the length of a string. 
  10356.  
  10357.  
  10358. ΓòÉΓòÉΓòÉ 9.45. @LINE - Read a random line from a file ΓòÉΓòÉΓòÉ
  10359.  
  10360. @LINE[filename,n]:  Returns line "n" from the specified file. The first line in 
  10361. the file is numbered 0.  "**EOF**" is returned for all line numbers beyond the 
  10362. end of the file.  If you need to scan through the lines of a file in sequence, 
  10363. the @FILEREAD function (above) and the "@filename" construct available in the 
  10364. FOR command are much faster than calling the @LINE function repeatedly.  @LINE 
  10365. will retrieve input from standard input if you specify CON as the filename.  If 
  10366. you are redirecting input to @LINE using this feature, you must use command 
  10367. grouping or the redirection will not work properly.  For example: 
  10368.  
  10369.         (echo %@line[con,0]) < myfile.dat
  10370.  
  10371.  
  10372. ΓòÉΓòÉΓòÉ 9.46. @LINES - Count lines in a file ΓòÉΓòÉΓòÉ
  10373.  
  10374. @LINES[filename]  Returns the line number of the last line in the file, or "-1" 
  10375. if the file is empty.  The first line in the file is numbered 0, so (for 
  10376. example) @LINES will return 0 for a file containing one line. 
  10377.  
  10378.  
  10379. ΓòÉΓòÉΓòÉ 9.47. @LOWER - Convert string to lower case ΓòÉΓòÉΓòÉ
  10380.  
  10381. @LOWER[string]:  Returns the string converted to lower case. 
  10382.  
  10383.  
  10384. ΓòÉΓòÉΓòÉ 9.48. @MAKEAGE - Convert date/time to file date/time ΓòÉΓòÉΓòÉ
  10385.  
  10386. @MAKEAGE[date[,time]]:  Returns the date and time (if included) as a single 
  10387. value in the same format as @FILEAGE.  Can be used to compare the time stamp of 
  10388. a file with a specific date and time. 
  10389.  
  10390.  
  10391. ΓòÉΓòÉΓòÉ 9.49. @MAKEDATE - Convert number of days to date ΓòÉΓòÉΓòÉ
  10392.  
  10393. @MAKEDATE[n]:  Returns a date (formatted according to the current country 
  10394. settings).  "n" is the number of days since 1/1/80. This is the inverse of 
  10395. @DATE. 
  10396.  
  10397.  
  10398. ΓòÉΓòÉΓòÉ 9.50. @MAKETIME - Convert number of seconds to time ΓòÉΓòÉΓòÉ
  10399.  
  10400. @MAKETIME[n]:  Returns a time (formatted according to the current country 
  10401. settings).  "n" is the number of seconds since midnight.  This is the inverse 
  10402. of @TIME. 
  10403.  
  10404.  
  10405. ΓòÉΓòÉΓòÉ 9.51. @NAME - File name without path or extension ΓòÉΓòÉΓòÉ
  10406.  
  10407. @NAME[filename]:  Returns the base name of a file, without the path or 
  10408. extension. 
  10409.  
  10410.  
  10411. ΓòÉΓòÉΓòÉ 9.52. @NUMERIC - Test if a string is numeric ΓòÉΓòÉΓòÉ
  10412.  
  10413. @NUMERIC[string]:  Returns "1" if the argument is composed entirely of digits 
  10414. (0 to 9), signs (+ or -), and the thousands and decimal separators.  Otherwise, 
  10415. returns "0". 
  10416.  
  10417.  
  10418. ΓòÉΓòÉΓòÉ 9.53. @PATH - File path without name ΓòÉΓòÉΓòÉ
  10419.  
  10420. @PATH[filename]:  Returns the path from a file name, including the drive letter 
  10421. and a trailing backslash but not including the base name or extension. 
  10422.  
  10423.  
  10424. ΓòÉΓòÉΓòÉ 9.54. @RANDOM - Generate a random integer ΓòÉΓòÉΓòÉ
  10425.  
  10426. @RANDOM[min, max]:  Returns a random value between min and max, inclusive. 
  10427. Min, max, and the returned value are all integers. 
  10428.  
  10429.  
  10430. ΓòÉΓòÉΓòÉ 9.55. @READSCR - Read characters from the screen ΓòÉΓòÉΓòÉ
  10431.  
  10432. @READSCR[row,col,length]:  Returns the text displayed on the screen at the 
  10433. specified location.  The upper left corner of the screen is location 0,0. 
  10434.  
  10435. You can also specify the row and column as offsets from the current cursor 
  10436. position.  Begin the value with a plus sign [+] to read the screen the 
  10437. specified number of rows below (or columns to the right of) the current 
  10438. position, or with a minus sign [-] to read the screen above (or to the left of) 
  10439. the current position. 
  10440.  
  10441.  
  10442. ΓòÉΓòÉΓòÉ 9.56. @READY - Drive ready status (0 or 1) ΓòÉΓòÉΓòÉ
  10443.  
  10444. @READY[d:]:  Returns "1" if the specified drive is ready; otherwise returns 
  10445. "0". 
  10446.  
  10447.  
  10448. ΓòÉΓòÉΓòÉ 9.57. @REMOTE - Remote (network) drive detection (0 or 1) ΓòÉΓòÉΓòÉ
  10449.  
  10450. @REMOTE[d:]:  Returns "1" if the specified drive is a remote (network) drive; 
  10451. otherwise returns "0". 
  10452.  
  10453.  
  10454. ΓòÉΓòÉΓòÉ 9.58. @REMOVABLE - Removable drive detection (0 or 1) ΓòÉΓòÉΓòÉ
  10455.  
  10456. @REMOVABLE[d:]:  Returns "1" if the specified drive is removable (i.e., a 
  10457. floppy disk or removable hard disk); otherwise returns "0". 
  10458.  
  10459.  
  10460. ΓòÉΓòÉΓòÉ 9.59. @REPEAT - Repeat a character ΓòÉΓòÉΓòÉ
  10461.  
  10462. @REPEAT[c,n]:  Returns the character "c" repeated "n" times. 
  10463.  
  10464.  
  10465. ΓòÉΓòÉΓòÉ 9.60. @REXX - Execute a REXX expression ΓòÉΓòÉΓòÉ
  10466.  
  10467. @REXX[expr]:  Calls the REXX interpreter to execute the expression. Returns the 
  10468. result string from REXX; if the REXX expression does not return a string, @REXX 
  10469. returns the REXX numeric result code. 
  10470.  
  10471.  
  10472. ΓòÉΓòÉΓòÉ 9.61. @SEARCH - Path search ΓòÉΓòÉΓòÉ
  10473.  
  10474. @SEARCH[filename]:  Searches for the filename using the PATH environment 
  10475. variable, appending an extension if one isn't specified. Returns the 
  10476. fully-expanded name of the file including drive, path, base name, and 
  10477. extension, or an empty string if a matching file is not found.  If wildcards 
  10478. are used in the filename, @SEARCH will search for the first file that matches 
  10479. the wildcard specification, and return the drive and path for that file plus 
  10480. the wildcard filename (e.g., E:\UTIL\*.COM). (See the PATH command for details 
  10481. on the default extensions used when searching the PATH and the order in which 
  10482. the search proceeds.) 
  10483.  
  10484.  
  10485. ΓòÉΓòÉΓòÉ 9.62. @SELECT - Menu selection ΓòÉΓòÉΓòÉ
  10486.  
  10487. @SELECT[filename,top,left,bottom,right,title]:  Pops up a selection window with 
  10488. the lines from the specified file. Returns the text of the line the scrollbar 
  10489. is on if you press Enter, or an empty string if you press Esc.  @SELECT can be 
  10490. used to display menus or other selection lists from a batch file.  To select 
  10491. from lines passed through input redirection or a pipe, use CON as the filename. 
  10492. You can move through the selection window with standard navigation keystrokes. 
  10493. To change the navigation keys, see the Key Mapping directives in the .INI file. 
  10494.  
  10495.  
  10496. ΓòÉΓòÉΓòÉ 9.63. @SUBSTR - Extract a substring ΓòÉΓòÉΓòÉ
  10497.  
  10498. @SUBSTR[string,start,length]:  Returns a substring, starting at the position 
  10499. "start" and continuing for "length" characters.  If the length is omitted, it 
  10500. will default to the remainder of the string.  If the length is negative, the 
  10501. start is relative to the right side of the string.  The first character in the 
  10502. string is numbered 0; if the length is negative, the last character is numbered 
  10503. 0.  For example, %@SUBSTR[%_TIME,0,2] gets the current time and extracts the 
  10504. hour.  If the string includes commas, it must be quoted with double quotes ["] 
  10505. or back quotes [`].  The quotes do count in calculating the position of the 
  10506. substring. @INSTR performs the same function, and allows commas in the string 
  10507. without quoting. 
  10508.  
  10509.  
  10510. ΓòÉΓòÉΓòÉ 9.64. @TIME - Convert time to number of seconds ΓòÉΓòÉΓòÉ
  10511.  
  10512. @TIME[hh:mm:ss]:  Returns the number of seconds since midnight for the 
  10513. specified time.  The time must be in 24-hour format; "am" and "pm" cannot be 
  10514. used. 
  10515.  
  10516.  
  10517. ΓòÉΓòÉΓòÉ 9.65. @TIMER - Elapsed time of specified timer ΓòÉΓòÉΓòÉ
  10518.  
  10519. @TIMER[n]:  Returns the current split time for a stopwatch started with the 
  10520. TIMER command.  The value of n specifies the timer to read and can be 1, 2, or 
  10521. 3. 
  10522.  
  10523.  
  10524. ΓòÉΓòÉΓòÉ 9.66. @TRIM - Remove blanks from a string ΓòÉΓòÉΓòÉ
  10525.  
  10526. @TRIM[string]:  Returns the string with the leading and trailing white space 
  10527. (space and tab characters) removed. 
  10528.  
  10529.  
  10530. ΓòÉΓòÉΓòÉ 9.67. @UNIQUE - Create file with unique name ΓòÉΓòÉΓòÉ
  10531.  
  10532. @UNIQUE[d:\path]:  Creates a zero-length file with a unique name in the 
  10533. specified directory, and returns the full name and path.  If no path is 
  10534. specified, the file will be created in the current directory.  The file name 
  10535. will be FAT-compatible (8 character name and 3-character extension) regardless 
  10536. of the type of drive on which the file is created.  This function allows you to 
  10537. create a  temporary file without overwriting an existing file. 
  10538.  
  10539.  
  10540. ΓòÉΓòÉΓòÉ 9.68. @UPPER - Convert string to upper case ΓòÉΓòÉΓòÉ
  10541.  
  10542. @UPPER[string]:  Returns the string converted to upper case. 
  10543.  
  10544.  
  10545. ΓòÉΓòÉΓòÉ 9.69. @WORD - Extract a word from a string ΓòÉΓòÉΓòÉ
  10546.  
  10547. @WORD[["xxx",]n,string]:  Returns the "nth" word in a string.  The first word 
  10548. is numbered 0.  If "n" is negative, words are returned from the end of the 
  10549. string.  You can use the first argument, "xxx" to specify the separators that 
  10550. you wish to use.  If you want to use a double quote as a separator, prefix it 
  10551. with an escape character.  If you don't specify a list of separators, @WORD 
  10552. will consider only spaces, tabs, and commas as word separators.  For example: 
  10553.  
  10554.         %@WORD[2,NOW IS THE TIME]    returns "THE"
  10555.         %@WORD[-0,NOW IS THE TIME]   returns "TIME"
  10556.         %@WORD[-2,NOW IS THE TIME]   returns "IS"
  10557.         %@WORD["=",1,2 + 2=4]        returns "4"
  10558.  
  10559.  
  10560. ΓòÉΓòÉΓòÉ 9.70. @WORDS - Convert string to upper case ΓòÉΓòÉΓòÉ
  10561.  
  10562. @WORDS[["xxx"],string]  Returns the number of words in the string.  The 
  10563. optional list of delimiters follows the same format as @WORD.  If the string 
  10564. argument is enclosed in quotation marks, you must enter a list of delimiters as 
  10565. well. 
  10566.  
  10567.  
  10568. ΓòÉΓòÉΓòÉ 10. Configuring Take Command ΓòÉΓòÉΓòÉ
  10569.  
  10570. This section covers the configuration of Take Command, including: 
  10571.  
  10572.     Startup Options 
  10573.  
  10574.     File Locations 
  10575.     Configuration Notebook 
  10576.     TCMDOS2.INI 
  10577.  
  10578.  
  10579. ΓòÉΓòÉΓòÉ 10.1. Startup ΓòÉΓòÉΓòÉ
  10580.  
  10581. You will typically start Take Command from an icon on your OS/2 desktop. 
  10582. Usually a single object is sufficient, but if you wish you can create multiple 
  10583. objects to start Take Command in different modes, with different startup 
  10584. commands or options, or to run different batch files or other commands.  You 
  10585. can use these objects to run commonly-used commands and batch files directly 
  10586. from the OS/2 desktop. 
  10587.  
  10588. Each object or icon represents a different Take Command window.  You can set 
  10589. any necessary command line parameters for Take Command such as a command to be 
  10590. executed, any desired switches, and the name and path for TCMDOS2.INI.  More 
  10591. information on command line switches and options for Take Command is included 
  10592. later in this topic. 
  10593.  
  10594. When you configure a Take Command object, place the full path and name for the 
  10595. TCMDOS2.EXE file in the Path and File Name field on the Program page of the 
  10596. object's Settings notebook, and put any startup options that you want passed to 
  10597. Take Command (e.g., the name of a startup batch file) in the Parameters field. 
  10598. (To bring up the Settings notebook click on the object with mouse button 2, 
  10599. then click on the Settings item on the popup menu.)  For example: 
  10600.  
  10601.         Path and File Name:    C:\TCMDOS2\TCMDOS2.EXE
  10602.         Parameters:            C:\GO.BAT
  10603.         Working directory:     C:\
  10604.  
  10605. When Take Command starts it automatically runs the optional TCSTART batch file. 
  10606. You can use this file to load aliases and environment variables and otherwise 
  10607. initialize Take Command. 
  10608.  
  10609. You can also place the name of a batch file, internal or external command, or 
  10610. alias at the end of the Parameters field for any object (as shown in the 
  10611. example above).  The batch file, command, or alias will be executed after 
  10612. TCSTART but before the first prompt is displayed. 
  10613.  
  10614. Each OS/2 program -- including Take Command -- has a command line which can be 
  10615. used to pass information to the program when it starts.  When Take Command is 
  10616. started from an object on the OS/2 desktop, the command line is entered in the 
  10617. Parameters field on the Program page of the Settings notebook for the Take 
  10618. Command object. 
  10619.  
  10620. The Take Command startup command line does not need to contain any information. 
  10621. When invoked with an empty command line, Take Command will configure itself 
  10622. from the TCMDOS2.INI file, run TCSTART, and then display a prompt and wait for 
  10623. you to type a command.  However, you may add information to the startup command 
  10624. line that will affect the way Take Command operates. 
  10625.  
  10626. Take Command recognizes several optional fields on the command line. If you use 
  10627. more than one of these fields, their order is important.  The syntax for the 
  10628. command line is: 
  10629.  
  10630. [@d:\path\inifile] [//iniline]... [/L] [/LA] [/LD] [/LH] [/C] [command] 
  10631.  
  10632. The options are: 
  10633.  
  10634. @d:\path\inifile:  This option sets the path and name of the TCMDOS2.INI file. 
  10635. You do not need this option if you aren't using a TCMD.INI file, or if the file 
  10636. is named TCMDOS2.INI and is stored in the same subdirectory as TCMDOS2.EXE. 
  10637.  
  10638. //iniline:  This option tells Take Command to treat the text appearing between 
  10639. the // and the next space or tab as a TCMDOS2.INI directive. The directive 
  10640. should be in the same format as a line in the [TakeCommand] section of 
  10641. TCMDOS2.INI, but it may not contain spaces, tabs, or comments.  This option 
  10642. overrides any corresponding directive in your TCMDOS2.INI file. 
  10643.  
  10644. /L, /LA, /LD, and /LH:  These options force Take Command to use a local alias, 
  10645. directory history, and / or command history list. This allows you to use global 
  10646. aliases as the default, but start a specific Take Command session with local 
  10647. aliases or history.  See ALIAS for details on local and global aliases, 
  10648. Directory History Window for details on local and global directory history, and 
  10649. Command History for details on local and global command history. /LA forces 
  10650. local aliases, /LD forces local directory history, /LH forces local command 
  10651. history, and /L forces all three. 
  10652.  
  10653. [/C] command:  This option tells Take Command to run a command when it starts. 
  10654. The command will be run after TCSTART has been executed and before any command 
  10655. prompt is displayed.  It can be any valid internal or external command, batch 
  10656. file, or alias; you may include multiple commands by using the command 
  10657. separator.  All other startup options must be placed before the command, 
  10658. because Take Command will treat characters after the command as part of the 
  10659. command and not as additional startup options. 
  10660.  
  10661. When the command is preceded by a /C, Take Command will execute the command and 
  10662. then exit and return to the parent program or the OS/2 desktop without 
  10663. displaying a prompt. 
  10664.  
  10665. To run a specific startup batch file or other command when a particular Take 
  10666. Command object is started, include the batch file or command name (with a path, 
  10667. if the file is not in the startup directory) as the last item in the Parameters 
  10668. field.  The batch file or command will be executed after any TCSTART file, but 
  10669. before the first prompt is displayed. 
  10670.  
  10671. You can use this capability to run a specific batch file or command for a 
  10672. particular object (as opposed to TCSTART, which is run every time Take Command 
  10673. starts). 
  10674.  
  10675. For example, to run C:\STARTUP.BAT when the object starts: 
  10676.  
  10677.         Path and File Name:    C:\TCMDOS2\TCMDOS2.EXE
  10678.         Parameters:            C:\STARTUP.BAT
  10679.         Working directory:     C:\
  10680.  
  10681. To execute an internal or external command, an alias, or a batch file and then 
  10682. exit (return to the desktop) when it is done, place /Ccommand (rather than just 
  10683. command) as the last item in the Parameters field.  For example: 
  10684.  
  10685.         Path and File Name:    C:\TCMDOS2\TCMDOS2.EXE
  10686.         Parameters:            /C C:\STARTUP.BAT
  10687.         Working directory:     C:\
  10688.  
  10689.  
  10690. ΓòÉΓòÉΓòÉ 10.2. File Locations ΓòÉΓòÉΓòÉ
  10691.  
  10692. The automated Take Command installation program places all Take Command for 
  10693. OS/2 files in a single directory.  You may move the files to different 
  10694. directories if you wish, but you must make sure that the files can be found by 
  10695. the programs that need to use them.  The following information will help you 
  10696. set up your system correctly if you are moving the files: 
  10697.  
  10698.         TCOS2DLL.DLL is a library used by TCMDOS2.EXE.  This file must be in a 
  10699.         directory which is included in the LIBPATH setting in CONFIG.SYS.  You 
  10700.         can either add the Take Command for OS/2 directory to the LIBPATH 
  10701.         setting, or copy TCOS2DLL.DLL to a standard library directory such as 
  10702.         \OS2\DLL. 
  10703.  
  10704.         TCMDOS2.INF contains this help text.  For the help system to work 
  10705.         properly, the directory containing this file must be included in the 
  10706.         SET BOOKSHELF command in CONFIG.SYS.  You can either add the Take 
  10707.         Command for OS/2 directory to the BOOKSHELF setting, or copy 
  10708.         TCMDOS2.INF to a standard help directory such as \OS2\BOOK. 
  10709.  
  10710.         TCMDOS2H.MSG contains the help text for the /? option that is available 
  10711.         as part of each internal command.  For this feature to work properly, 
  10712.         the directory containing this file must be included in the SET DPATH 
  10713.         command in CONFIG.SYS.  You can either add the Take Command for OS/2 
  10714.         directory to the DPATH setting, or copy TCMDOS2H.MSG to a standard 
  10715.         DPATH directory such as \OS2. 
  10716.  
  10717.         SHRALIAS.EXE is a small utility that saves the shared alias, history, 
  10718.         and directory history lists between Take Command sessions (it is loaded 
  10719.         with the SHRALIAS command).  This file should be in the Take Command 
  10720.         directory, or in a directory listed in your PATH statement.  If it is 
  10721.         not, the SHRALIAS command will fail. 
  10722.  
  10723.  
  10724. ΓòÉΓòÉΓòÉ 10.3. Configuration Notebook ΓòÉΓòÉΓòÉ
  10725.  
  10726. The dialogs in the Take Command for OS/2 configuration notebook control the 
  10727. configuration of Take Command.  Each option on one of the notebook pages a 
  10728. corresponding directive in TCMDOS2.INI.  You can start the configuration 
  10729. notebook with the Configure Take Command selection on the Setup menu. 
  10730.  
  10731. Most changes you make in the configuration notebook will take effect 
  10732. immediately.  If you return to Take Command by selecting the OK button, new 
  10733. settings will only stay in effect until you end the current Take Command 
  10734. session.  If you return to Take Command by selecting Save, the changes will be 
  10735. recorded in the [TakeCommand] section of TCMDOS2.INI and will be in effect each 
  10736. time you start Take Command.  Changes made on the Startup page, if saved, will 
  10737. take effect the next time you start Take Command, but will not affect the 
  10738. current Take Command session. 
  10739.  
  10740. While you are using the dialogs, you can move between sets of configuration 
  10741. options with the tabs on the right hand side of the notebook.  The sets of 
  10742. options available in the notebook are: 
  10743.  
  10744.     Startup Options 
  10745.     Display Options 
  10746.     Command Line Options 
  10747.     General Options 1 
  10748.     General Options 2 
  10749.     Command Options 
  10750.  
  10751.  
  10752. ΓòÉΓòÉΓòÉ 10.3.1. Startup Options Page ΓòÉΓòÉΓòÉ
  10753.  
  10754. You can use this page to set startup options in TCMDOS2.INI.  Most changes you 
  10755. make will take effect immediately.  If you return to Take Command by selecting 
  10756. the OK button, new settings will only stay in effect until you end the current 
  10757. Take Command session.  If you return to Take Command by selecting Save, the 
  10758. changes will be recorded in TCMDOS2.INI and will be in effect each time you 
  10759. start Take Command.  Changes made on the Startup page, if saved, will take 
  10760. effect the next time you start Take Command, but will not affect the current 
  10761. Take Command session. 
  10762.  
  10763. The TCSTART and TCEXIT Path field lets you set the path to TCSTART and TCEXIT 
  10764. if they aren't in the same directory as Take Command, and sets the TCStartPath 
  10765. directive. 
  10766.  
  10767. In the TCMDOS2.INI section, you can set the value of the INIQuery directive. 
  10768.  
  10769. In the Buffer Sizes section: 
  10770.  
  10771.         *   Command History sets the size of the command history list, and the 
  10772.             value of the History directive. 
  10773.  
  10774.         *   Directory History sets the size of the  directory history list, and 
  10775.             the value of the DirHistory directive. 
  10776.  
  10777.  The Display section sets the size and location of Take Command's window when 
  10778.  it starts up: 
  10779.  
  10780.         *   Standard, Max, Min, and Custom set the WindowState directive. 
  10781.  
  10782.         *   The window position and size fields set the WindowX, WindowY, 
  10783.             WindowHeight, and WindowWidth directives.  Use these if you want 
  10784.             Take Command to start up at a specific location on your desktop. 
  10785.             These fields are ignored unless the item above is set to Custom. 
  10786.  
  10787.  The Cursor section sets the shape of the cursor and the IBeamCursor directive. 
  10788.  Use the I-Beam shape for normal systems, and the Arrow shape for laptop or 
  10789.  other systems where the I-Beam cursor is hard to see. 
  10790.  
  10791.  
  10792. ΓòÉΓòÉΓòÉ 10.3.2. Display Options Page ΓòÉΓòÉΓòÉ
  10793.  
  10794. You can use this page to set display-related options in TCMDOS2.INI.  Most 
  10795. changes you make will take effect immediately.  If you return to Take Command 
  10796. by selecting the OK button, new settings will only stay in effect until you end 
  10797. the current Take Command session.  If you return to Take Command by selecting 
  10798. Save, the changes will be recorded in TCMDOS2.INI and will be in effect each 
  10799. time you start Take Command. 
  10800.  
  10801. The Text Dimensions section configures the way that text appears in Take 
  10802. Command's main window: 
  10803.  
  10804.         *   Width sets the number of columns that Take Command uses for its 
  10805.             displays and sets the ScreenColumns directive. 
  10806.  
  10807.         *   Tabs selects the location of tab stops and sets the TabStops 
  10808.             directive. 
  10809.  
  10810.  The Options section controls the appearance of the Tool Bar (sets the 
  10811.  ToolBarOn directive) and the Status Bar (sets the StatusBarOn directive), and 
  10812.  enables or disables ANSI support (sets the ANSI directive).  The tool bar and 
  10813.  status bar settings are also modified when you enable and disable the 
  10814.  corresponding option on the Setup menu. 
  10815.  
  10816.  The Scrolling section controls Take Command's screen scrollback buffer: 
  10817.  
  10818.         *   Buffer Size sets the size of the screen buffer, and the value of 
  10819.             the ScreenBufSize directive. Valid sizes are from 16,000 to 256,000 
  10820.             bytes. 
  10821.  
  10822.         *   Scroll Lines controls how much the screen scrolls when Take 
  10823.             Command's text has reached the bottom of the window, and sets the 
  10824.             ScrollLines directive.  Lower values produce slower but smoother 
  10825.             scrolling. 
  10826.  
  10827.  The Colors section sets default screen colors: 
  10828.  
  10829.         *   Output establishes the default colors Take Command uses for the 
  10830.             text it displays, and sets the StdColors directive. 
  10831.  
  10832.         *   Input establishes the colors for echoing the commands you type, and 
  10833.             sets the InputColors directive. 
  10834.  
  10835.  
  10836. ΓòÉΓòÉΓòÉ 10.3.3. Command Line Options Page ΓòÉΓòÉΓòÉ
  10837.  
  10838. You can use this page to set command line options in TCMDOS2.INI.  Most changes 
  10839. you make will take effect immediately.  If you return to Take Command by 
  10840. selecting the OK button, new settings will only stay in effect until you end 
  10841. the current Take Command session.  If you return to Take Command by selecting 
  10842. Save, the changes will be recorded in TCMDOS2.INI and will be in effect each 
  10843. time you start Take Command. 
  10844.  
  10845. The Editing section controls command-line editing: 
  10846.  
  10847.         *   Default Mode selects whether you begin editing in Overstrike or 
  10848.             Insert mode, and sets the EditMode directive. 
  10849.  
  10850.         *   Cursor sets the width of the cursor for both Overstrike and Insert 
  10851.             modes, and sets the CursorIns and CursorOver directives. The width 
  10852.             is expressed as a percentage of the width of a character cell. 
  10853.  
  10854.  In the Command History section: 
  10855.  
  10856.         *   The Scroll / History keys setting controls whether Take Command or 
  10857.             4OS2 defaults are used for scrolling through the scrollback buffer 
  10858.             and the command history.  The Normal setting uses the arrow and 
  10859.             PgUp / PgDn keys for the scrollback buffer, and the corresponding 
  10860.             control keys (Ctrl-Up, Ctrl-Down, etc.) for the command history. 
  10861.             The Swapped setting reverses these assignments.  For more details 
  10862.             see Scrolling and History Keystrokes.  This option sets the value 
  10863.             of the SwapScrollKeys directive. 
  10864.  
  10865.         *   Minimum saved characters sets the size of the shortest line that 
  10866.             will be saved in the command history, and sets the value of the 
  10867.             HistMin directive. 
  10868.  
  10869.         *   Copy to end, if checked, copies a recalled command to the end of 
  10870.             the history list each time it is executed, and sets the HistCopy 
  10871.             directive. 
  10872.  
  10873.  The History Windows section sets the position and size of the popup history 
  10874.  window and sets the HistWinLeft, HistWinTop, HistWinWidth, and HistWinHeight 
  10875.  directives. 
  10876.  
  10877.  
  10878. ΓòÉΓòÉΓòÉ 10.3.4. Options 1 Page ΓòÉΓòÉΓòÉ
  10879.  
  10880. You can use this page to set options in TCMDOS2.INI.  Most changes you make 
  10881. will take effect immediately.  If you return to Take Command by selecting the 
  10882. OK button, new settings will only stay in effect until you end the current Take 
  10883. Command session.  If you return to Take Command by selecting Save, the changes 
  10884. will be recorded in TCMDOS2.INI and will be in effect each time you start Take 
  10885. Command. 
  10886.  
  10887. The Descriptions section sets the way that Take Command handles file 
  10888. descriptions entered with the DESCRIBE command: 
  10889.  
  10890.         *   The Enable checkbox enables or disables the display and processing 
  10891.             of descriptions, and sets the Descriptions directive. 
  10892.  
  10893.         *   The Maximum Length field determines the maximum size of file 
  10894.             descriptions and sets the DescriptionMax directive.  The value can 
  10895.             range from 20 to 512 characters.  This value sets the size of the 
  10896.             internal description buffers; the actual description limit is 1 
  10897.             character less.  For example, if you set the limit to 512, the 
  10898.             longest description you can use is 511 characters. 
  10899.  
  10900.  The Special Characters section sets the characters that have special meaning 
  10901.  for Take Command.  See 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility for 
  10902.  information on how to change these to make Take Command more compatible with 
  10903.  4DOS, 4OS2, and 4DOS/NT. 
  10904.  
  10905.         *   Separator is the character that separates multiple commands.  It 
  10906.             can also be set with the CommandSep directive or SETDOS /C. 
  10907.  
  10908.         *   Escape sets the character used to suppress the normal meaning of 
  10909.             the following character.  It can also be set with the EscapeChar 
  10910.             directive or SETDOS /E. 
  10911.  
  10912.         *   Parameter sets the character used after a percent sign to specify 
  10913.             all or all remaining command-line arguments in a batch file or 
  10914.             alias.  It can also be set with the ParameterChar directive or with 
  10915.             SETDOS /P. 
  10916.  
  10917.  Default Beep sets defaults for the BEEP command and for "error" beeps.  To 
  10918.  disable error beeps, set the beep length to 0, and be sure to specify an 
  10919.  explicit length each time you use the BEEP command. 
  10920.  
  10921.         *   Length sets the length of the beep in timer ticks that are 
  10922.             approximately 1/18 of a second each.  It also sets the BeepLength 
  10923.             directive. 
  10924.  
  10925.         *   Frequency sets the frequency of the beep in Hz.  It also sets the 
  10926.             BeepFreq directive. 
  10927.  
  10928.  The Options section sets miscellaneous options: 
  10929.  
  10930.         *   Force upper case, when selected, forces Take Command to display 
  10931.             file names in upper case in internal commands like DIR and COPY. 
  10932.             You can use the UpperCase directive or the SETDOS /U command 
  10933.             achieve the same result.  Force upper case has no effect on 
  10934.             filenames from volumes which support long filenames. 
  10935.  
  10936.         *   Default batch echo, if selected, turns on echoing in batch files by 
  10937.             default.  You can use the BatchEcho directive or the SETDOS /V 
  10938.             command to achieve the same result. 
  10939.  
  10940.         *   Protect redirected output files, if selected, keeps Take Command 
  10941.             from overwritng an existing file with redirected (>) output or from 
  10942.             creating a new file with output redirected in append (>>) mode. 
  10943.             You can achieve the same result with the NoClobber directive or the 
  10944.             SETDOS /N command. 
  10945.  
  10946.         *   The Time options determine how Take Command displays times.  If you 
  10947.             select Country, the time display is based on your country settings 
  10948.             in OS/2.  The am/pm setting forces a 12-hour display with a 
  10949.             trailing "a" or "p."  The 24-hour setting forces a standard 24-hour 
  10950.             display. You can also set the time display with the AmPm directive. 
  10951.  
  10952.  
  10953. ΓòÉΓòÉΓòÉ 10.3.5. Options 2 Page ΓòÉΓòÉΓòÉ
  10954.  
  10955. You can use this page to set options in TCMDOS2.INI.  Most changes you make 
  10956. will take effect immediately.  If you return to Take Command by selecting the 
  10957. OK button, new settings will only stay in effect until you end the current Take 
  10958. Command session.  If you return to Take Command by selecting Save, the changes 
  10959. will be recorded in TCMDOS2.INI and will be in effect each time you start Take 
  10960. Command. 
  10961.  
  10962. The Logging section enables or disables Command and History logging (see the 
  10963. LOG command) and sets the file name to use for each.  It also sets the LogName 
  10964. and HistLogName directives. 
  10965.  
  10966. The Eval Precision sets the minimum and maximum number of digits after the 
  10967. decimal point that @EVAL will display.  You can achieve the same results with 
  10968. the EvalMin and EvalMax directives or with the SETDOS /F command. 
  10969.  
  10970. The External Programs setting controls whether Take Command waits for 
  10971. applications to complete before displaying the prompt.  This setting applies 
  10972. only to applications started from the Take Command prompt, including DOS 
  10973. applications.  Take Command will always wait for applications run from batch 
  10974. files.  It also has no effect on "TTY" applications run within the Take Command 
  10975. window, or on applications started with the START command, which has its own 
  10976. separate /WAIT switch.  This option sets the ExecWait directive. 
  10977.  
  10978.  
  10979. ΓòÉΓòÉΓòÉ 10.3.6. Command Options Page ΓòÉΓòÉΓòÉ
  10980.  
  10981. You can use this page to set options related to specific commands in 
  10982. TCMDOS2.INI.  Most changes you make will take effect immediately.  If you 
  10983. return to Take Command by selecting the OK button, new settings will only stay 
  10984. in effect until you end the current Take Command session.  If you return to 
  10985. Take Command by selecting Save, the changes will be recorded in TCMDOS2.INI and 
  10986. will be in effect each time you start Take Command. 
  10987.  
  10988. The DIR Colors field sets the colors used by DIR.  You can achieve the same 
  10989. effect with the ColorDir directive or by setting the COLORDIR environment 
  10990. variable.  See Color Coded Directories for details. 
  10991.  
  10992. The LIST section sets the foreground and background colors for the LIST 
  10993. command.  It also sets the ListColors directive. 
  10994.  
  10995. The SELECT section sets the foreground and background colors for the SELECT 
  10996. command.  It also sets the SelectColors directive. 
  10997.  
  10998. The Editor Filename sets the path and name of the program you want to use when 
  10999. you use when you select Editor from the Utilities menu.  It also sets the 
  11000. Editor directive. 
  11001.  
  11002.  
  11003. ΓòÉΓòÉΓòÉ 10.4. TCMDOS2.INI ΓòÉΓòÉΓòÉ
  11004.  
  11005. The configuration of Take Command is controlled through an optional file of 
  11006. initialization information called TCMDOS2.INI.  You can modify this file 
  11007. manually with an ASCII editor, but in most cases you will probably find it 
  11008. easier and faster to modify it using the configuration notebook, available on 
  11009. the Setup menu. 
  11010.  
  11011. The .INI file has several sections.  All of the directives described here go 
  11012. into in the [TakeCommand] section, which is usually first in the file.  You can 
  11013. edit this section manually. Take Command uses the other sections to record 
  11014. information you set while you are using it, including its window size and 
  11015. position, the font you are using, and the buttons you create on the tool bar. 
  11016. You should use Take Command's menu commands to change the settings in these 
  11017. other sections of the .INI file instead of editing them directly. 
  11018.  
  11019. The Advanced directives, the Key Mapping directives, and a few other individual 
  11020. directives do not have corresponding fields in the configuration notebook, and 
  11021. must be entered manually (this is noted for each individual directive which 
  11022. requires manual entry). 
  11023.  
  11024. This topic contains general information on TCMDOS2.INI. For information on 
  11025. specific directives see the separate topic for each type of directive: 
  11026.  
  11027.     Initialization Directives 
  11028.     Configuration Directives 
  11029.     Color Directives 
  11030.     Key Mapping Directives 
  11031.     Advanced Directives 
  11032.  
  11033. These topics list the directives, with a one-line description of each, and a 
  11034. cross-reference which selects a full screen help topic on that directive. A few 
  11035. of the directives are simple enough that the one-line description is 
  11036. sufficient, but in most cases you should check for any additional information 
  11037. in the cross-reference topic if you are not already familiar with the 
  11038. directive. 
  11039.  
  11040. You can also obtain help on most directives with a HELP directive command at 
  11041. the prompt. 
  11042.  
  11043. Take Command reads TCMDOS2.INI when it starts, and configures itself 
  11044. accordingly.  The file is not re-read when you change it manually.  For changes 
  11045. to take effect, you must restart Take Command.  However, if you make changes 
  11046. with the configuration notebook those changes will take effect immediately. 
  11047.  
  11048. Each item that you can include in the [TakeCommand] section of TCMDOS2.INI has 
  11049. a default value.  You only need to include entries in this section for settings 
  11050. that you want to change from their default values.  If you are happy with all 
  11051. of the default values, you can leave the [TakeCommand] section of the file 
  11052. empty. 
  11053.  
  11054. Take Command searches for TCMDOS2.INI in two places: 
  11055.  
  11056.         *   If there is an "@d:\path\inifile" option on the Take Command 
  11057.             startup command line Take Command will use the path and file name 
  11058.             specified there, and will not look elsewhere. 
  11059.  
  11060.         *   If there is no .INI file name on the startup command line, the 
  11061.             search proceeds to the same directory where the Take Command 
  11062.             program file (TCMDOS2.EXE ) is stored.  This is the "normal" 
  11063.             location for the .INI file.  Take Command determines this directory 
  11064.             automatically. 
  11065.  
  11066.  Most lines in the .INI file consist of a one-word directive, an equal sign 
  11067.  [=], and a value.  For example, in the following line, the word "History" is 
  11068.  the directive and "2048" is the value: 
  11069.  
  11070.           History = 2048
  11071.  
  11072.  Any spaces before or after the equal sign are ignored. 
  11073.  
  11074.  If you have a long string to enter in the .INI file (for example, for the 
  11075.  ColorDir directive), you must enter it all on one line. Strings cannot be 
  11076.  "continued" to a second line.  Each line may be up to 1023 characters long. 
  11077.  
  11078.  The format of the value part of a directive line depends on the individual 
  11079.  directive.  It may be a numeric value, a single character, a choice (like 
  11080.  "Yes" or "No"), a color setting, a key name, a path, a filename, or a text 
  11081.  string.  The value begins with the first non-blank character after the equal 
  11082.  sign and ends at the end of the line or the beginning of a comment. 
  11083.  
  11084.  Blank lines are ignored in the .INI file and can be used to separate groups of 
  11085.  directives.  You can place comments in the file by beginning a line with a 
  11086.  semicolon [;].  You can also place comments at the end of any line except one 
  11087.  containing a text string value.  To do so, enter at least one space or tab 
  11088.  after the value, a semicolon, and your comment, like this: 
  11089.  
  11090.           History = 2048       ;set history list size
  11091.  
  11092.  If you try to place a comment at the end of a string value, the comment will 
  11093.  become part of the string and will probably cause an error. 
  11094.  
  11095.  When Take Command detects an error while processing the .INI file, it displays 
  11096.  an error message and prompts you to press a key to continue processing the 
  11097.  file.  This allows you to note any errors before the startup process 
  11098.  continues.  The directive in error will retain its previous or default value. 
  11099.  Only the most catastrophic errors (like a disk read failure) will terminate 
  11100.  processing of the remainder of the .INI file.  If you don't want a pause after 
  11101.  each error, use a PauseOnError = No directive at the beginning of TCMDOS2.INI. 
  11102.  
  11103.  If you need to test different values for an .INI directive without repeatedly 
  11104.  editing the .INI file, see INIQuery. 
  11105.  
  11106.  The SETDOS command can override several of the .INI file directives.  For 
  11107.  example, the cursor shape used by Take Command can be adjusted either with the 
  11108.  CursorIns and CursorOver directives or the SETDOS /S command.  The 
  11109.  correspondence between SETDOS options and .INI directives is noted under each 
  11110.  directive below, and under each option of the SETDOS command. 
  11111.  
  11112.  
  11113. ΓòÉΓòÉΓòÉ 10.4.1. Initialization Directives ΓòÉΓòÉΓòÉ
  11114.  
  11115. The directives in this section control how Take Command starts and where it 
  11116. looks for its files. The initialization directives are: 
  11117.  
  11118.         DirHistory          Size of directory history list. 
  11119.         HelpBook            Books to load in help system 
  11120.         History             Size of history list 
  11121.         INIQuery            Query for each line in TCMDOS2.INI 
  11122.         LocalAliases        ehp1. Local vs. global aliases 
  11123.         LocalHistory        Local vs. global history 
  11124.         LocalDirHistory     Local vs. global directory history 
  11125.         PauseOnError        Pause on errors in TCMDOS2.INI 
  11126.         ScreenBufSize       Size of screen buffer. 
  11127.         TCStartPath         Path for TCSTART and TCEXIT 
  11128.         WindowState         Initial state for the Take Command window 
  11129.         WindowX, WindowY, WindowWidth, WindowHeightInitial size and position of 
  11130.                             the Take Command window 
  11131.  
  11132.  
  11133. ΓòÉΓòÉΓòÉ 10.4.1.1. DirHistory ΓòÉΓòÉΓòÉ
  11134.  
  11135. DirHistory = nnnn (256):  Sets the amount of memory allocated to the directory 
  11136. history list in bytes.  The allowable range of values is 128 to 2048.  If you 
  11137. use a global directory history list (see Directory History Window), the 
  11138. DirHistory value is ignored in all sessions except that which fist establishes 
  11139. the global list. 
  11140.  
  11141.  
  11142. ΓòÉΓòÉΓòÉ 10.4.1.2. HelpBook ΓòÉΓòÉΓòÉ
  11143.  
  11144. HelpBook = String:  Sets the names of the "books" to be loaded when Take 
  11145. Command for OS/2 help is invoked with the HELP command or theF1 key.  The 
  11146. default is TCMDOS2 which loads only the Take Command for OS/2 help. 
  11147.  
  11148. For example, to load both the Take Command for OS/2 help and the OS/2 Command 
  11149. Reference when you press F1 or enter the HELP command: 
  11150.  
  11151.         HelpBook = TCMDOS2+CMDREF
  11152.  
  11153. (For this statement to work the CMDREF.INF file must be available in a 
  11154. directory listed in your BOOKSHELF path in CONFIG.SYS.) 
  11155.  
  11156.  
  11157. ΓòÉΓòÉΓòÉ 10.4.1.3. History (directive) ΓòÉΓòÉΓòÉ
  11158.  
  11159. History = nnnn (1024):  Sets the amount of memory allocated to the command 
  11160. history list in bytes.  The allowable range of values is 256 to 32767 bytes. 
  11161. If you use a global history list (see Command History and Recall), the History 
  11162. value is ignored in all shells except the shell which first establishes the 
  11163. global list. 
  11164.  
  11165.  
  11166. ΓòÉΓòÉΓòÉ 10.4.1.4. INIQuery ΓòÉΓòÉΓòÉ
  11167.  
  11168. INIQuery = Yes | NO:  If set to Yes, a prompt will be displayed before 
  11169. execution of each subsequent line in the current .INI file.  This allows you to 
  11170. modify certain directives when you start Take Command in order to test 
  11171. different configurations.  INIQuery can be reset to No at any point in the 
  11172. file.  Normally INIQuery = Yes is only used during testing of other .INI file 
  11173. directives. 
  11174.  
  11175. The prompt generated by INIQuery = Yes is: 
  11176.  
  11177.         [contents of the line]  (Y/N/Q/R/E)  ?
  11178.  
  11179. At this prompt, you may enter: 
  11180.  
  11181.         Y = Yes:    Process this line and go on to the next. 
  11182.         N = No:     Skip this line and go on to the next. 
  11183.         Q = Quit:   Skip this line and all subsequent lines. 
  11184.         R = Rest:   Execute this and all subsequent lines. 
  11185.         E = Edit:   Edit the value for this entry. 
  11186.  
  11187.  
  11188. ΓòÉΓòÉΓòÉ 10.4.1.5. LocalAliases ΓòÉΓòÉΓòÉ
  11189.  
  11190. LocalAliases = Yes | NO:  No forces all copies of Take Command to share the 
  11191. same alias list.  Yes keeps the lists for each shell separate.  See ALIAS for 
  11192. more details on local and global alias lists. 
  11193.  
  11194.  
  11195. ΓòÉΓòÉΓòÉ 10.4.1.6. LocalDirHistory ΓòÉΓòÉΓòÉ
  11196.  
  11197. LocalDirHistory = Yes | NO:  No forces all copies of Take Command to share the 
  11198. same directory history list. Yes keeps the list for each session separate. See 
  11199. directory history window for more details on local and global directory 
  11200. history. 
  11201.  
  11202.  
  11203. ΓòÉΓòÉΓòÉ 10.4.1.7. LocalHistory ΓòÉΓòÉΓòÉ
  11204.  
  11205. LocalHistory = Yes | NO:  No forces all copies of Take Command to share the 
  11206. same history list.  Yes keeps the lists for each shell separate.  See Command 
  11207. History and Recall for more details on local and global history lists. 
  11208.  
  11209.  
  11210. ΓòÉΓòÉΓòÉ 10.4.1.8. PauseOnError ΓòÉΓòÉΓòÉ
  11211.  
  11212. PauseOnError = YES | No:  Yes forces a pause with the message "Error in 
  11213. filename, press any key to continue processing" after displaying any error 
  11214. message related to a specific line in the .INI file.  No continues processing 
  11215. with no pause after an error message is displayed. 
  11216.  
  11217.  
  11218. ΓòÉΓòÉΓòÉ 10.4.1.9. ScreenBufSize ΓòÉΓòÉΓòÉ
  11219.  
  11220. ScreenBufSize = nnnn (64000):  Sets the size of the screen scrollback buffer in 
  11221. bytes.  The allowable range is from 16,000 to 256,000 bytes. 
  11222.  
  11223.  
  11224. ΓòÉΓòÉΓòÉ 10.4.1.10. TCStartPath ΓòÉΓòÉΓòÉ
  11225.  
  11226. TCStartPath = Path:  Sets the drive and directory where the TCSTART and TCEXIT 
  11227. batch files (if any) are located. 
  11228.  
  11229.  
  11230. ΓòÉΓòÉΓòÉ 10.4.1.11. WindowState ΓòÉΓòÉΓòÉ
  11231.  
  11232. WindowState = STANDARD | Maximize | Minimize | Custom: Sets the initial state 
  11233. of the Take Command window.  Standard puts the window in the default position 
  11234. on the OS/2 desktop, and is the default setting. Maximize maximizes the window; 
  11235. Minimize minimizes it, and Custom sets it to the position specified by the 
  11236. WindowX, WindowY, WindowWidth, WindowHeight directives. 
  11237.  
  11238.  
  11239. ΓòÉΓòÉΓòÉ 10.4.1.12. WindowX, WindowY, WindowWidth, WindowHeight ΓòÉΓòÉΓòÉ
  11240.  
  11241. WindowX = nnnn, WindowY = nnnn, WindowWidth = nnnn, WindowHeight = nnnn:  These 
  11242. 4 directives set the initial size and position of the Take Command window.  The 
  11243. measurements are in pixels or pels.  WindowX and WindowY refer to the position 
  11244. of the bottom left corner of the window relative to the bottom left corner of 
  11245. the screen.  These directives will be ignored unless WindowState is set to 
  11246. Custom. 
  11247.  
  11248.  
  11249. ΓòÉΓòÉΓòÉ 10.4.2. Configuration Directives ΓòÉΓòÉΓòÉ
  11250.  
  11251. These directives control the way that Take Command operate.  Some can be 
  11252. changed with the SETDOS command while Take Command is running. Any 
  11253. corresponding SETDOS command is listed in the description of each directive. 
  11254. The configuration directives are: 
  11255.  
  11256.         AmPm                Time display format 
  11257.         BatchEcho           Default batch file echo state 
  11258.         BeepFreq            Default beep frequency 
  11259.         BeepLength          Default beep length 
  11260.         CommandSep          Multiple command separator character 
  11261.         CursorIns           Cursor width in insert mode 
  11262.         CursorOver          Cursor width in overstrike mode 
  11263.         DescriptionMax      Maximum length of file descriptions 
  11264.         DescriptionName     Name of file to hold file descriptions 
  11265.         Descriptions        Enable / disable description processing 
  11266.         EditMode            Editing mode (insert / overstrike) 
  11267.         Editor              Program to run for "Editor" menu choice 
  11268.         EvalMax             Maximum precision returned by @EVAL 
  11269.         EvalMin             Minimum precision returned by @EVAL 
  11270.         ExecWait            Forces Take Command to wait for external programs 
  11271.                             to complete 
  11272.         EscapeChar          Take Command escape character 
  11273.         HistCopy            History copy mode 
  11274.         HistLogName         History log file name 
  11275.         HistMin             Minimum command length to save 
  11276.         HistWinHeight       History window height 
  11277.         HistWinLeft         History window left side position 
  11278.         HistWinTop          History window top position 
  11279.         HistWinWidth        History window width 
  11280.         IBeamCursor         Change the default text cursor to an arrow 
  11281.         LogName             Log file name 
  11282.         NoClobber           Overwrite protection for output redirection 
  11283.         ParameterChar       Alias / batch file parameter character 
  11284.         ScreenColumns       Virtual screen width 
  11285.         ScrollLines         Number of lines to scroll up when at the bottom of 
  11286.                             the window 
  11287.         StatusBarOn         Set status bar mode at startup 
  11288.         StatBarText         Point size of status bar text 
  11289.         SwapFilePath        Path to OS/2 swap file 
  11290.         SwapScrollKeys      Use the 4OS2-style keys for history recall 
  11291.         TabStops            Sets the tab positions for Take Command's output 
  11292.         ToolBarOn           Set toolbar mode at startup 
  11293.         ToolBarText         Point size of toolbar text 
  11294.         UpperCase           Force file names to upper case 
  11295.  
  11296.  
  11297. ΓòÉΓòÉΓòÉ 10.4.2.1. AmPm ΓòÉΓòÉΓòÉ
  11298.  
  11299. AmPm = Yes | NO | Auto:  Yes displays times in 12-hour format with a trailing 
  11300. "a" for AM or "p" for PM.  The default of No forces a display in 24-hour time 
  11301. format.  Auto formats the time according to the country code set for your 
  11302. system. AmPm controls the time displays used by DIR and SELECT, in LOG files, 
  11303. and the output of the TIMER, DATE, and TIME commands.  It has no effect on 
  11304. %_TIME, %@MAKETIME, the $t and $T options of PROMPT, or date and time ranges. 
  11305.  
  11306.  
  11307. ΓòÉΓòÉΓòÉ 10.4.2.2. ANSI ΓòÉΓòÉΓòÉ
  11308.  
  11309. ANSI = YES | No:  Sets the initial state of ANSI support.  Yes enables ANSI 
  11310. string processing in the Take Command window (for example, ANSI strings can be 
  11311. displayed in the prompt, or with the ECHO command)  No disables ANSI strings. 
  11312. Also see SETDOS /A. 
  11313.  
  11314. You can test whether ANSI support is enabled with the _ANSI internal variable. 
  11315.  
  11316. See the ANSI Reference for more details on ANSI strings, and a reference list 
  11317. of ANSI sequences supported by Take Command for OS/2. 
  11318.  
  11319.  
  11320. ΓòÉΓòÉΓòÉ 10.4.2.3. BatchEcho ΓòÉΓòÉΓòÉ
  11321.  
  11322. BatchEcho = YES | No:  Sets the default batch echo mode. Yes enables echoing of 
  11323. all batch file commands unless ECHO is explicitly set off in the batch file. 
  11324. No disables batch file echoing unless ECHO is explicitly set on.  Also see 
  11325. SETDOS /V. 
  11326.  
  11327.  
  11328. ΓòÉΓòÉΓòÉ 10.4.2.4. BeepFreq ΓòÉΓòÉΓòÉ
  11329.  
  11330. BeepFreq = nnnn (440):  Sets the default BEEP command frequency in Hz.  This is 
  11331. also the frequency for "error" beeps (for example, if you press an illegal 
  11332. key).  To disable all error beeps set this or BeepLength to 0.  If you do, the 
  11333. BEEP command will still be operable, but will not produce sound unless you 
  11334. explicitly specify the frequency and duration. 
  11335.  
  11336.  
  11337. ΓòÉΓòÉΓòÉ 10.4.2.5. BeepLength ΓòÉΓòÉΓòÉ
  11338.  
  11339. BeepLength = nnnn (2):  Sets the default BEEP length in system clock ticks 
  11340. (approximately 1/18 of a second per tick). BeepLength is also the default 
  11341. length for "error" beeps (for example, if you press an illegal key). 
  11342.  
  11343.  
  11344. ΓòÉΓòÉΓòÉ 10.4.2.6. CommandSep ΓòÉΓòÉΓòÉ
  11345.  
  11346. CommandSep = c:  This is the character used to separate multiple commands on 
  11347. the same line.  The default for Take Command is the ampersand [&]. You cannot 
  11348. use any of the redirection characters (| > < ) or any of the whitespace 
  11349. characters (space, tab, comma, or equal sign).  Also see SETDOS /C, the %+ 
  11350. internal variable, and 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility for 
  11351. information on using compatible command separators for two or more products. 
  11352.  
  11353.  
  11354. ΓòÉΓòÉΓòÉ 10.4.2.7. CursorIns ΓòÉΓòÉΓòÉ
  11355.  
  11356. CursorIns = nnnn (15):  This is the width of the cursor for insert mode during 
  11357. command-line editing and all commands which accept line input (DESCRIBE, ESET, 
  11358. etc.).  The size is a percentage of the total character cell size, between 0% 
  11359. and 100%.  Because of the way video drivers map the cursor shape, you may not 
  11360. get a smooth progression in cursor shapes as CursorIns and CursorOver change. 
  11361. If you set CursorIns and CursorOver to -1, the cursor shape won't be modified 
  11362. at all.  If you set them to 0, the cursor will be invisible. Also see SETDOS 
  11363. /S. 
  11364.  
  11365.  
  11366. ΓòÉΓòÉΓòÉ 10.4.2.8. CursorOver ΓòÉΓòÉΓòÉ
  11367.  
  11368. CursorOver = nnnn (100):  This is the width of the cursor for overstrike mode 
  11369. during command-line editing and all commands which accept line input.  The size 
  11370. is a percentage of the total character cell size, between 0% and 100%.  For 
  11371. more details see the CursorIns directive; also see SETDOS /S. 
  11372.  
  11373.  
  11374. ΓòÉΓòÉΓòÉ 10.4.2.9. DescriptionMax ΓòÉΓòÉΓòÉ
  11375.  
  11376. DescriptionMax = nnnn (512):  Controls the description length limit for 
  11377. DESCRIBE.  The allowable range is 20 to 512 characters.  This sets the size of 
  11378. the internal description buffers; the actual description limit is 1 character 
  11379. less.  For example, if you set DescriptionMax = 512, the longest description 
  11380. you can use is 511 characters. 
  11381.  
  11382.  
  11383. ΓòÉΓòÉΓòÉ 10.4.2.10. DescriptionName ΓòÉΓòÉΓòÉ
  11384.  
  11385. DescriptionName = File:  Sets the name of the hidden file in each directory 
  11386. that will hold file descriptions.  If you don't use this directive, the 
  11387. description files will be named DESCRIPT.ION.  This directive cannot be entered 
  11388. via the configuration notebook; you must enter it manually (see TCMDOS2.INI for 
  11389. details).  Use this directive with caution, because changing the name from the 
  11390. default will make it difficult to transfer file descriptions to another system. 
  11391. Also see SETDOS /D. 
  11392.  
  11393.  
  11394. ΓòÉΓòÉΓòÉ 10.4.2.11. Descriptions ΓòÉΓòÉΓòÉ
  11395.  
  11396. Descriptions = YES | No:  Turns description handling on or off during the file 
  11397. processing commands COPY, DEL, MOVE, and REN.  If set to No, Take Command will 
  11398. not update the description file when files are moved, copied, deleted or 
  11399. renamed.  Also see SETDOS /D. 
  11400.  
  11401.  
  11402. ΓòÉΓòÉΓòÉ 10.4.2.12. EditMode ΓòÉΓòÉΓòÉ
  11403.  
  11404. EditMode = INSERT | Overstrike:  This directive lets you start the command-line 
  11405. editor in either insert or overstrike mode.  Also see SETDOS /M. 
  11406.  
  11407.  
  11408. ΓòÉΓòÉΓòÉ 10.4.2.13. Editor ΓòÉΓòÉΓòÉ
  11409.  
  11410. Editor = File:  Specifies the path and filename of the program that Take 
  11411. Command will execute when you select "Editor" from the Utilities menu.  The 
  11412. default is the standard OS/2 editor E.EXE. 
  11413.  
  11414.  
  11415. ΓòÉΓòÉΓòÉ 10.4.2.14. EvalMax ΓòÉΓòÉΓòÉ
  11416.  
  11417. EvalMax = nnnn (8):  Controls the maximum number of digits after the decimal 
  11418. point in values returned by @EVAL.  You can override this setting with the 
  11419. construct @EVAL[expression=n,n].  The allowable range is 0 to 8. Also see 
  11420. SETDOS /F. 
  11421.  
  11422.  
  11423. ΓòÉΓòÉΓòÉ 10.4.2.15. EvalMin ΓòÉΓòÉΓòÉ
  11424.  
  11425. EvalMin = nnnn (0):  Controls the minimum number of digits after the decimal 
  11426. point in values returned by @EVALF_EVAL.  The allowable range is 0 to 8.  This 
  11427. directive will be ignored if EvalMin is larger than EvalMax.  You can override 
  11428. this setting with the construct @EVAL[expression=n,n].  Also see SETDOS /F. 
  11429.  
  11430.  
  11431. ΓòÉΓòÉΓòÉ 10.4.2.16. ExecWait ΓòÉΓòÉΓòÉ
  11432.  
  11433. ExecWait = Yes | NO:  Controls whether Take Command waits for an external 
  11434. program to complete before redisplaying the prompt. 
  11435.  
  11436. This setting applies only to applications started from the Take Command prompt. 
  11437. Take Command will always wait for applications run from batch files.  ExecWait 
  11438. also has no effect on "TTY" applications run within the Take Command window, or 
  11439. on applications started with the START command, which has its own separate 
  11440. /WAIT switch. 
  11441.  
  11442.  
  11443. ΓòÉΓòÉΓòÉ 10.4.2.17. EscapeChar ΓòÉΓòÉΓòÉ
  11444.  
  11445. EscapeChar = c:  Sets the character used to suppress the normal meaning of the 
  11446. following character.  The default for Take Command is a a caret [^]. See Escape 
  11447. Character for a description of special escape sequences.  You cannot use any of 
  11448. the redirection characters (|, >, or < ) or the whitespace characters (space, 
  11449. tab, comma, or equal sign) as the escape character.  Also see SETDOS /E, the %= 
  11450. internal variable, and 4DOS, 4OS2, 4DOS/NT and Take Command Compatibility for 
  11451. information on using compatible escape characters for two or more products. 
  11452.  
  11453.  
  11454. ΓòÉΓòÉΓòÉ 10.4.2.18. HistCopy ΓòÉΓòÉΓòÉ
  11455.  
  11456. HistCopy = Yes | NO:  Controls what happens when you re-execute a line from the 
  11457. command history.  If this option is set to Yes, the line is appended to the end 
  11458. of the history list.  By default, or if this option is set to No, no copy of 
  11459. the command is made.  The original copy of the command is always retained at 
  11460. its original position in the list, regardless of the setting of HistCopy. 
  11461.  
  11462.  
  11463. ΓòÉΓòÉΓòÉ 10.4.2.19. HistLogName ΓòÉΓòÉΓòÉ
  11464.  
  11465. HistLogName = File:  Sets the history log file name and path.  Using 
  11466. HistLogName does not turn history logging on; you must use a LOG /H ON command 
  11467. to do so. 
  11468.  
  11469.  
  11470. ΓòÉΓòÉΓòÉ 10.4.2.20. HistMin ΓòÉΓòÉΓòÉ
  11471.  
  11472. HistMin = nnnn (0):  Sets the minimum command-line size to save in the command 
  11473. history list.  Any command line whose length is less than this value will not 
  11474. be saved.  Legal values range from 0, which saves everything, to 1024, which 
  11475. disables all command history saves. 
  11476.  
  11477.  
  11478. ΓòÉΓòÉΓòÉ 10.4.2.21. HistWinHeight ΓòÉΓòÉΓòÉ
  11479.  
  11480. HistWinHeight = nn (12):  Sets the height of the command-line and directory 
  11481. history windows in lines, including the border.  Legal values range from 5 to 
  11482. the height of your Take Command window. 
  11483.  
  11484.  
  11485. ΓòÉΓòÉΓòÉ 10.4.2.22. HistWinLeft ΓòÉΓòÉΓòÉ
  11486.  
  11487. HistWinLeft = nn (20):  Sets the horizontal position of the left side of the 
  11488. command-line and directory history windows.  Legal values range from 0 (the 
  11489. left edge of the Take Command window) to the number of columns in your Take 
  11490. Command window minus 10. 
  11491.  
  11492.  
  11493. ΓòÉΓòÉΓòÉ 10.4.2.23. HistWinTop ΓòÉΓòÉΓòÉ
  11494.  
  11495. HistWinTop = nn (1):  Sets the vertical position of the top of the command-line 
  11496. and directory history windows.  Legal values range from 0 (the top of the Take 
  11497. Command window) to the number of rows in your Take Command window minus 5. 
  11498.  
  11499.  
  11500. ΓòÉΓòÉΓòÉ 10.4.2.24. HistWinWidth ΓòÉΓòÉΓòÉ
  11501.  
  11502. HistWinWidth = nn (36):  Sets the width of the command-line and directory 
  11503. history windows in characters, including the border. Legal values range from 10 
  11504. to the width of your Take Command window. 
  11505.  
  11506.  
  11507. ΓòÉΓòÉΓòÉ 10.4.2.25. IBeamCursor ΓòÉΓòÉΓòÉ
  11508.  
  11509. IBeamCursor = YES | No:  If set to Yes, Take Command will display the standard 
  11510. "I-Beam" cursor in text areas of its window.  If IBeamCursor is set to No, an 
  11511. arrow is used in all areas of the window. This option is intended for LCD 
  11512. screens where the I-beam cursor may be hard to see. 
  11513.  
  11514.  
  11515. ΓòÉΓòÉΓòÉ 10.4.2.26. LogName ΓòÉΓòÉΓòÉ
  11516.  
  11517. LogName = File:  Sets the log file name and path. Using LogName does not turn 
  11518. logging on; you must use a LOG ON command to do so. 
  11519.  
  11520.  
  11521. ΓòÉΓòÉΓòÉ 10.4.2.27. NoClobber ΓòÉΓòÉΓòÉ
  11522.  
  11523. NoClobber = Yes | NO:  If set to Yes, will prevent standard output redirection 
  11524. from overwriting an existing file, and will require that the output file 
  11525. already exist for append redirection.  Also see SETDOS /N. 
  11526.  
  11527.  
  11528. ΓòÉΓòÉΓòÉ 10.4.2.28. ParameterChar ΓòÉΓòÉΓòÉ
  11529.  
  11530. ParameterChar = c:  Sets the character used after a percent sign to specify all 
  11531. or all remaining command-line arguments in a batch file or alias (e.g., %$ or 
  11532. %n$.; see Batch Files and ALIAS).  The default in Take Command is the dollar 
  11533. sign [$].  Also see SETDOS /P.  See 4DOS, 4OS2, 4DOS/NT and Take Command 
  11534. Compatibility for information on using compatible parameter characters for two 
  11535. or more products. 
  11536.  
  11537.  
  11538. ΓòÉΓòÉΓòÉ 10.4.2.29. ScreenColumns ΓòÉΓòÉΓòÉ
  11539.  
  11540. ScreenColumns = nnnn:  Sets the number of virtual screen columns used by the 
  11541. video display.  If the virtual window width is greater than the physical window 
  11542. width, Take Command will display a horizontal scrollbar at the bottom of the 
  11543. window.  If you attempt to drag the right margin to a size greater than the 
  11544. virtual screen width, Take Command will resize the window to the virtual width. 
  11545. The default value is 80. 
  11546.  
  11547.  
  11548. ΓòÉΓòÉΓòÉ 10.4.2.30. ScrollLines ΓòÉΓòÉΓòÉ
  11549.  
  11550. ScrollLines = nnnn (2):  Sets the number of lines displayed before the screen 
  11551. is physically scrolled.  Take Command will scroll up when output reaches the 
  11552. bottom of the window. Higher values will speed up the display but also make it 
  11553. jerky; lower values will make scrolling smoother but will slow it down. 
  11554.  
  11555.  
  11556. ΓòÉΓòÉΓòÉ 10.4.2.31. StatusBarOn ΓòÉΓòÉΓòÉ
  11557.  
  11558. StatusBarOn = YES | No:  Yes enables the status bar when Take Command starts. 
  11559. No disables it.  The status bar can always be enabled or disabled while Take 
  11560. Command is running by using the Setup menu. 
  11561.  
  11562.  
  11563. ΓòÉΓòÉΓòÉ 10.4.2.32. StatBarText ΓòÉΓòÉΓòÉ
  11564.  
  11565. StatBarText = nnnn (8):  Sets the point size of the text on the status bar. 
  11566. The allowable range is 4 to 16. 
  11567.  
  11568.  
  11569. ΓòÉΓòÉΓòÉ 10.4.2.33. SwapFilePath ΓòÉΓòÉΓòÉ
  11570.  
  11571. SwapFilePath = Path:  Specifies the path of the OS/2 swap file so the MEMORY 
  11572. command and the status bar  can find it and display its size. 
  11573.  
  11574. This directive is only required if the swap file is not stored in the 
  11575. \OS2\SYSTEM directory of the boot drive.  It can include a drive and directory 
  11576. only (in which case the standard file name, SWAPPER.DAT, will be used), or a 
  11577. drive, directory, and complete file name. 
  11578.  
  11579. This directive cannot be entered via the configuration notebook; you must enter 
  11580. it manually (see TCMDOS2.INI for details). 
  11581.  
  11582.  
  11583. ΓòÉΓòÉΓòÉ 10.4.2.34. SwapScrollKeys ΓòÉΓòÉΓòÉ
  11584.  
  11585. SwapScrollKeys = Yes | NO:  Yes switches to 4OS2-style keystrokes for 
  11586. manipulating the scrollback buffer. 
  11587.  
  11588. If SwapScrollKeys is set to Yes, the Up and Down arrow keys will scroll through 
  11589. the command history list and the PgUp key will pop up the history window.  The 
  11590. Ctrl-Up, Ctrl-Down, Ctrl-PgUp, and Ctrl-PgDn keys will scroll the text in the 
  11591. screen buffer. 
  11592.  
  11593. If SwapScrollKeys is set to No, these keys will assume their default meanings. 
  11594. The Up and Down arrow keys and the PgUp and PgDn keys will scroll the text in 
  11595. the screen buffer.  The Ctrl-Up and Ctrl-Down keys will scroll through the 
  11596. command history list and the Ctrl-PgUp key will pop up the history window. 
  11597.  
  11598. For additional details see Scrolling and History Keystrokes. 
  11599.  
  11600. Do not set SwapScrollKeys to Yes if you use key mapping directives to reassign 
  11601. the scrolling or history keys individually.  SwapScrollKeys takes effect before 
  11602. other key mappings, and using both methods at the same time will be confusing 
  11603. at best.  Setting SwapScrollKeys to Yes has essentially the same effect as 
  11604. including the following key mapping directives in TCMDOS2.INI individually: 
  11605.  
  11606.         PrevHistory = Up
  11607.         NextHistory = Down
  11608.         HistWinOpen = PgUp
  11609.         HistWinOpen = PgDn
  11610.         ScrollUp = Ctrl-Up
  11611.         ScrollDown = Ctrl-Down
  11612.         ScrollPgUp = Ctrl-PgUp
  11613.         ScrollPgDn = Ctrl-PgDn
  11614.  
  11615.  
  11616. ΓòÉΓòÉΓòÉ 10.4.2.35. TabStops ΓòÉΓòÉΓòÉ
  11617.  
  11618. TabStops = nnnn (8):  Sets the tab stops for Take Command's output (including 
  11619. the output from the LIST and TYPE commands).  The allowable range is 1 to 32. 
  11620.  
  11621.  
  11622. ΓòÉΓòÉΓòÉ 10.4.2.36. ToolBarOn ΓòÉΓòÉΓòÉ
  11623.  
  11624. ToolBarOn = YES | No:  Yes enables the tool bar when Take Command starts.  No 
  11625. disables it.  The tool bar can be enabled or disabled while Take Command is 
  11626. running by using the Setup menu. 
  11627.  
  11628.  
  11629. ΓòÉΓòÉΓòÉ 10.4.2.37. ToolBarText ΓòÉΓòÉΓòÉ
  11630.  
  11631. ToolBarText = nnnn (8):  Sets the point size of text on the tool bar.  The 
  11632. allowable range is 4 to 16. 
  11633.  
  11634.  
  11635. ΓòÉΓòÉΓòÉ 10.4.2.38. UpperCase ΓòÉΓòÉΓòÉ
  11636.  
  11637. UpperCase = Yes | NO:  Yes specifies that filenames should be displayed in the 
  11638. traditional upper-case by internal commands like COPY and DIR.  No allows the 
  11639. normal Take Command lower-case style. This directive does not affect the 
  11640. display of filenames on drives which support long filenames.  Also see SETDOS 
  11641. /U. 
  11642.  
  11643.  
  11644. ΓòÉΓòÉΓòÉ 10.4.3. Color Directives ΓòÉΓòÉΓòÉ
  11645.  
  11646. These directives control the colors that Take Command use for its displays. 
  11647. For complete details on color names and numbers, see Colors and Color Names. 
  11648. The color directives are: 
  11649.  
  11650.         ColorDir            Directory colors 
  11651.         InputColors         Input colors 
  11652.         ListColors          Colors used in the LIST display 
  11653.         SelectColors        Colors used in the SELECT display 
  11654.         StdColors           Standard display colors 
  11655.  
  11656.  
  11657. ΓòÉΓòÉΓòÉ 10.4.3.1. ColorDIR (directive) ΓòÉΓòÉΓòÉ
  11658.  
  11659. ColorDir = ext1 ext2 ...:colora;ext3 ext4... :colorb; ...: Sets the directory 
  11660. colors used by DIR.  The format is the same as that used for the COLORDIR 
  11661. environment variable.  See Color-Coded Directories for a detailed explanation. 
  11662.  
  11663.  
  11664. ΓòÉΓòÉΓòÉ 10.4.3.2. InputColors ΓòÉΓòÉΓòÉ
  11665.  
  11666. InputColors = Color:  Sets the colors used for command-line input.  This 
  11667. setting is useful for making your input stand out from the normal output. 
  11668.  
  11669.  
  11670. ΓòÉΓòÉΓòÉ 10.4.3.3. ListColors ΓòÉΓòÉΓòÉ
  11671.  
  11672. ListColors = Color:  Sets the colors used by the LIST command.  If this 
  11673. directive is not used, LIST will use the current default colors set by the CLS 
  11674. or COLOR command or by the StdColors directive. 
  11675.  
  11676.  
  11677. ΓòÉΓòÉΓòÉ 10.4.3.4. SelectColors ΓòÉΓòÉΓòÉ
  11678.  
  11679. SelectColors = Color:  Sets the colors used by the SELECT command.  If this 
  11680. directive is not used, SELECT will use the current default colors set by the 
  11681. CLS or COLOR command or by the StdColors directive. 
  11682.  
  11683.  
  11684. ΓòÉΓòÉΓòÉ 10.4.3.5. StdColors ΓòÉΓòÉΓòÉ
  11685.  
  11686. StdColors = Color:  Sets the standard colors to be used when CLS is used 
  11687. without a color specification.  Using this directive is similar to placing a 
  11688. COLOR command in the TCSTART file. 
  11689.  
  11690.  
  11691. ΓòÉΓòÉΓòÉ 10.4.4. Key Mapping Directives ΓòÉΓòÉΓòÉ
  11692.  
  11693. These directives allow you to change the keys used for command-line editing and 
  11694. other internal functions.  They cannot be entered via the configuration 
  11695. notebook; you must enter them manually (see TCMDOS2.INI for details). 
  11696.  
  11697. They are divided into four types, depending on the context in which the keys 
  11698. are used.  For a discussion and list of directives for each type see: 
  11699.  
  11700.             General Input Keys 
  11701.             Command-Line Editing Keys 
  11702.             History and @SELECT Window Keys 
  11703.             LIST Keys 
  11704.             Scrollback Buffer Keys 
  11705.  
  11706.  Using a key mapping directive allows you to assign a different or additional 
  11707.  key to perform the function described.  For example, to use function key F3 to 
  11708.  invoke the HELP facility (normally invoked with F1): 
  11709.  
  11710.           Help = F3
  11711.  
  11712.  Any directive can be used multiple times to assign multiple keys to the same 
  11713.  function.  For example: 
  11714.  
  11715.           ListFind = F         ;F does a find in LIST
  11716.           ListFind = F4        ;F4 also does a find in LIST
  11717.  
  11718.  Use some care when you reassign keystrokes.  If you assign a default key to a 
  11719.  different function, it will no longer be available for its original use.  For 
  11720.  example, if you assign F1 to the AddFile directive (a part of filename 
  11721.  completion), the F1 key will no longer invoke the help system, so you will 
  11722.  probably want to assign a different key to Help. 
  11723.  
  11724.  See Keys and Key Names before using the key mapping directives. 
  11725.  
  11726.  Key assignments are processed before looking for keystroke aliases. For 
  11727.  example, if you assign Shift-F1 to HELP and also assign Shift-F1 to a key 
  11728.  alias, the key alias will be ignored. 
  11729.  
  11730.  Assigning a new keystroke for a function does not deassign the default 
  11731.  keystroke for the same function.  If you want to deassign one of the default 
  11732.  keys, use the NormalKey directive described below or the corresponding 
  11733.  directive for keys in the other key groups (NormalEditKey, NormalHWinKey, or 
  11734.  NormalListKey). 
  11735.  
  11736.  
  11737. ΓòÉΓòÉΓòÉ 10.4.4.1. General Input Keys ΓòÉΓòÉΓòÉ
  11738.  
  11739. These directives apply to all input.  They are in effect whenever Take Command 
  11740. requests input from the keyboard, including during command-line editing and the 
  11741. DESCRIBE, ESET, INPUT, LIST, and SELECT commands.  The general input keys are: 
  11742.  
  11743.         Backspace           Deletes the character to the left of the cursor 
  11744.         BeginLine           Moves the cursor to the start of the line 
  11745.         Del                 Deletes the character at the cursor 
  11746.         DelToBeginning      Deletes from the cursor to the start of the line 
  11747.         DelToEnd            Deletes from the cursor to the end of the line 
  11748.         DelWordLeft         Deletes the word to the left of the cursor 
  11749.         DelWordRight        Deletes the word to the right of the cursor 
  11750.         Down                Moves the cursor or scrolls the display down 
  11751.         EndLine             Moves the cursor to the end of the line 
  11752.         EraseLine           Deletes the entire line 
  11753.         ExecLine            Executes or accepts a line 
  11754.         Ins                 Toggles insert / overstrike mode 
  11755.         Left                Moves the cursor or scrolls the display left 
  11756.         NormalKey           Deassigns a key 
  11757.         Right               Moves the cursor or scrolls the display right 
  11758.         Up                  Moves the cursor or scrolls the display up 
  11759.         WordLeft            Moves the cursor left one word 
  11760.         WordRight           Moves the cursor right one word 
  11761.  
  11762.  
  11763. ΓòÉΓòÉΓòÉ 10.4.4.1.1. Backspace ΓòÉΓòÉΓòÉ
  11764.  
  11765. Backspace = Key (Bksp):  Deletes the character to the left of the cursor. 
  11766.  
  11767.  
  11768. ΓòÉΓòÉΓòÉ 10.4.4.1.2. BeginLine ΓòÉΓòÉΓòÉ
  11769.  
  11770. BeginLine = Key (Home):  Moves the cursor to the beginning of the line. 
  11771.  
  11772.  
  11773. ΓòÉΓòÉΓòÉ 10.4.4.1.3. Del (directive) ΓòÉΓòÉΓòÉ
  11774.  
  11775. Del = Key (Del):  Deletes the character at the cursor. 
  11776.  
  11777.  
  11778. ΓòÉΓòÉΓòÉ 10.4.4.1.4. DelToBeginning ΓòÉΓòÉΓòÉ
  11779.  
  11780. DelToBeginning = Key (Ctrl-Home):  Deletes from the cursor to the start of the 
  11781. line. 
  11782.  
  11783.  
  11784. ΓòÉΓòÉΓòÉ 10.4.4.1.5. DelToEnd ΓòÉΓòÉΓòÉ
  11785.  
  11786. DelToEnd = Key (Ctrl-End):  Deletes from the cursor to the end of the line. 
  11787.  
  11788.  
  11789. ΓòÉΓòÉΓòÉ 10.4.4.1.6. DelWordLeft ΓòÉΓòÉΓòÉ
  11790.  
  11791. DelWordLeft = Key (Ctrl-L):  Deletes the word to the left of the cursor. 
  11792.  
  11793.  
  11794. ΓòÉΓòÉΓòÉ 10.4.4.1.7. DelWordRight ΓòÉΓòÉΓòÉ
  11795.  
  11796. DelWordRight = Key (Ctrl-R, Ctrl-Bksp):  Deletes the word to the right of the 
  11797. cursor.  See ClearKeyMap if you need to remove the default mapping of Ctrl-Bksp 
  11798. to this function. 
  11799.  
  11800.  
  11801. ΓòÉΓòÉΓòÉ 10.4.4.1.8. Down ΓòÉΓòÉΓòÉ
  11802.  
  11803. Down = Key (Down):  Scrolls the display down one line in LIST; moves the cursor 
  11804. down one line in SELECT and in the command-line history, directory history, or 
  11805. %@SELECT window. (Scrolling down through the command history at the prompt is 
  11806. controlled by NextHistory, not by this directive.) 
  11807.  
  11808.  
  11809. ΓòÉΓòÉΓòÉ 10.4.4.1.9. EndLine ΓòÉΓòÉΓòÉ
  11810.  
  11811. EndLine = Key (End):  Moves the cursor to the end of the line. 
  11812.  
  11813.  
  11814. ΓòÉΓòÉΓòÉ 10.4.4.1.10. EraseLine ΓòÉΓòÉΓòÉ
  11815.  
  11816. EraseLine = Key (Esc):  Deletes the entire line. 
  11817.  
  11818.  
  11819. ΓòÉΓòÉΓòÉ 10.4.4.1.11. ExecLine ΓòÉΓòÉΓòÉ
  11820.  
  11821. ExecLine = Key (Enter):  Executes or accepts a line. 
  11822.  
  11823.  
  11824. ΓòÉΓòÉΓòÉ 10.4.4.1.12. Ins ΓòÉΓòÉΓòÉ
  11825.  
  11826. Ins = Key (Ins):  Toggles insert / overstrike mode during line editing. 
  11827.  
  11828.  
  11829. ΓòÉΓòÉΓòÉ 10.4.4.1.13. Left ΓòÉΓòÉΓòÉ
  11830.  
  11831. Left = Key (Left):  Moves the cursor left one character; scrolls the display 
  11832. left 8 columns in LIST; scrolls the display left 4 columns in the command-line, 
  11833. directory history, or %@SELECT window. 
  11834.  
  11835.  
  11836. ΓòÉΓòÉΓòÉ 10.4.4.1.14. NormalKey ΓòÉΓòÉΓòÉ
  11837.  
  11838. NormalKey = Key:  Deassigns a general input key in order to disable the usual 
  11839. meaning of the key within Take Command and/or make it available for keystroke 
  11840. aliases.  This will make the keystroke operate as a "normal" key with no 
  11841. special function.  For example: 
  11842.  
  11843.         NormalKey = Ctrl-End
  11844.  
  11845. will disable Ctrl-End, which is the standard "delete to end of line" key. 
  11846. Ctrl-End could then be assigned to a keystroke alias. Another key could be 
  11847. assigned the "delete to end of line" function with the DelToEnd directive. 
  11848.  
  11849.  
  11850. ΓòÉΓòÉΓòÉ 10.4.4.1.15. Right ΓòÉΓòÉΓòÉ
  11851.  
  11852. Right = Key (Right):  Moves the cursor right one character; scrolls the display 
  11853. right 8 columns in LIST; scrolls the display right 4 columns in the 
  11854. command-line history, directory history, or %@SELECT window. 
  11855.  
  11856.  
  11857. ΓòÉΓòÉΓòÉ 10.4.4.1.16. Up ΓòÉΓòÉΓòÉ
  11858.  
  11859. Up = Key (Up):  Scrolls the display up one line in LIST; moves the cursor up 
  11860. one line in SELECT and in the command-line history, directory history, or 
  11861. %@SELECT window.  (Scrolling up through the command history at the prompt is 
  11862. controlled by PrevHistory, not by this directive.) 
  11863.  
  11864.  
  11865. ΓòÉΓòÉΓòÉ 10.4.4.1.17. WordLeft ΓòÉΓòÉΓòÉ
  11866.  
  11867. WordLeft = Key (Ctrl-Left):  Moves the cursor left one word; scrolls the 
  11868. display left 40 columns in LIST. 
  11869.  
  11870.  
  11871. ΓòÉΓòÉΓòÉ 10.4.4.1.18. WordRight ΓòÉΓòÉΓòÉ
  11872.  
  11873. WordRight = Key (Ctrl-Right):  Moves the cursor right one word; scrolls the 
  11874. display right 40 columns in LIST. 
  11875.  
  11876.  
  11877. ΓòÉΓòÉΓòÉ 10.4.4.2. Command-Line Editing Keys ΓòÉΓòÉΓòÉ
  11878.  
  11879. These directives apply only to command-line editing.  They are only effective 
  11880. at the Take Command prompt.  The command-line editing keys are: 
  11881.  
  11882.         AddFile             Keeps filename completion entry and adds another 
  11883.         CommandEscape       Allows direct entry of a keystroke 
  11884.         DelHistory          Deletes a history list entry 
  11885.         EndHistory          Displays the last entry in the history list 
  11886.         Help                Invokes this help system 
  11887.         NextFile            Gets the next matching filename 
  11888.         NextHistory         Recalls the next command from the history 
  11889.         NormalEditKey       Deassigns a command-line editing key 
  11890.         PopFile             Opens the filename completion window 
  11891.         PrevFile            Gets the previous matching filename 
  11892.         PrevHistory         Recalls the previous command from the history 
  11893.         SaveHistory         Saves the command line without executing it 
  11894.  
  11895.  
  11896. ΓòÉΓòÉΓòÉ 10.4.4.2.1. AddFile ΓòÉΓòÉΓòÉ
  11897.  
  11898. AddFile = Key (Ctrl-Shift-Tab):  Keeps the current filename completion entry 
  11899. and inserts the next matching name. 
  11900.  
  11901.  
  11902. ΓòÉΓòÉΓòÉ 10.4.4.2.2. CommandEscape ΓòÉΓòÉΓòÉ
  11903.  
  11904. CommandEscape = Key (Alt-255):  Allows direct entry of a keystroke that would 
  11905. normally be interpreted as an editor command. 
  11906.  
  11907.  
  11908. ΓòÉΓòÉΓòÉ 10.4.4.2.3. DelHistory ΓòÉΓòÉΓòÉ
  11909.  
  11910. DelHistory = Key (Ctrl-D):  Deletes the displayed history list entry and 
  11911. displays the previous entry. 
  11912.  
  11913.  
  11914. ΓòÉΓòÉΓòÉ 10.4.4.2.4. EndHistory ΓòÉΓòÉΓòÉ
  11915.  
  11916. EndHistory = Key (Ctrl-E):  Displays the last entry in the history list. 
  11917.  
  11918.  
  11919. ΓòÉΓòÉΓòÉ 10.4.4.2.5. Help ΓòÉΓòÉΓòÉ
  11920.  
  11921. Help = Key (F1):  Invokes the HELP facility. 
  11922.  
  11923.  
  11924. ΓòÉΓòÉΓòÉ 10.4.4.2.6. NextFile ΓòÉΓòÉΓòÉ
  11925.  
  11926. NextFile = Key (F9, Tab):  Gets the next matching filename. See ClearKeyMap if 
  11927. you need to remove the default mapping of Tab to this function. 
  11928.  
  11929.  
  11930. ΓòÉΓòÉΓòÉ 10.4.4.2.7. NextHistory ΓòÉΓòÉΓòÉ
  11931.  
  11932. NextHistory = Key (Ctrl-Down):  Recalls the next command from the command 
  11933. history.  Also see Scrolling and History Keystrokes and the SwapScrollKeys 
  11934. directive. 
  11935.  
  11936.  
  11937. ΓòÉΓòÉΓòÉ 10.4.4.2.8. NormalEditKey ΓòÉΓòÉΓòÉ
  11938.  
  11939. NormalEditKey = Key:  Deassigns a command-line editing key in order to disable 
  11940. the usual meaning of the key while editing a command line, and/or make it 
  11941. available for keystroke aliases.  For additional details see NormalKey. 
  11942.  
  11943.  
  11944. ΓòÉΓòÉΓòÉ 10.4.4.2.9. PopFile ΓòÉΓòÉΓòÉ
  11945.  
  11946. PopFile = Key (F7, Ctrl-Tab):  Opens the filename completion window.  You may 
  11947. not be able to use Ctrl-Tab, because not all systems recognize it as a 
  11948. keystroke.  See ClearKeyMap if you need to remove the default mapping of 
  11949. Ctrl-Tab to this function. 
  11950.  
  11951.  
  11952. ΓòÉΓòÉΓòÉ 10.4.4.2.10. PrevFile ΓòÉΓòÉΓòÉ
  11953.  
  11954. PrevFile = Key (F8, Shift-Tab):  Gets the previous matching filename.  See 
  11955. ClearKeyMap if you need to remove the default mapping of Shift-Tab to this 
  11956. function. 
  11957.  
  11958.  
  11959. ΓòÉΓòÉΓòÉ 10.4.4.2.11. PrevHistory ΓòÉΓòÉΓòÉ
  11960.  
  11961. PrevHistory = Key (Ctrl-Up):  Recalls the previous command from the command 
  11962. history.  Also see Scrolling and History Keystrokes and the SwapScrollKeys 
  11963. directive. 
  11964.  
  11965.  
  11966. ΓòÉΓòÉΓòÉ 10.4.4.2.12. SaveHistory ΓòÉΓòÉΓòÉ
  11967.  
  11968. SaveHistory = Key (Ctrl-K):  Saves the command line in the command history list 
  11969. without executing it. 
  11970.  
  11971.  
  11972. ΓòÉΓòÉΓòÉ 10.4.4.3. History and @SELECT Window Keys ΓòÉΓòÉΓòÉ
  11973.  
  11974. These directives apply only to the command history window, the directory 
  11975. history window, and %@SELECT windows.  The History and @SELECT window keys are: 
  11976.  
  11977.         DirWinOpen          Opens the directory history window 
  11978.         HistWinBegin        Moves to the first line of the history window 
  11979.         HistWinDel          Deletes a line from within the history window 
  11980.         HistWinEdit         Moves a line from the history window to the prompt 
  11981.         HistWinEnd          Moves to the last line of the history window 
  11982.         HistWinExec         Executes the selected line in the history window 
  11983.         HistWinOpen         Opens the command history window 
  11984.         NormalHWinKey       Deassigns a history window key 
  11985.  
  11986.  
  11987. ΓòÉΓòÉΓòÉ 10.4.4.3.1. DirWinOpen ΓòÉΓòÉΓòÉ
  11988.  
  11989. DirWinOpen = Key (F6):  Opens the directory history window while at the command 
  11990. line.  Also see Scrolling and History Keystrokes. 
  11991.  
  11992.  
  11993. ΓòÉΓòÉΓòÉ 10.4.4.3.2. HistWinBegin ΓòÉΓòÉΓòÉ
  11994.  
  11995. HistWinBegin = Key (Ctrl-PgUp):  Moves to the first line of the history when in 
  11996. the history window. 
  11997.  
  11998.  
  11999. ΓòÉΓòÉΓòÉ 10.4.4.3.3. HistWinDel ΓòÉΓòÉΓòÉ
  12000.  
  12001. HistWinDel = Key (Ctrl-D):  Deletes a line from within the history window. 
  12002.  
  12003.  
  12004. ΓòÉΓòÉΓòÉ 10.4.4.3.4. HistWinEdit ΓòÉΓòÉΓòÉ
  12005.  
  12006. HistWinEdit = Key (Ctrl-Enter):  Moves a line from the history window to the 
  12007. prompt for editing. 
  12008.  
  12009.  
  12010. ΓòÉΓòÉΓòÉ 10.4.4.3.5. HistWinEnd ΓòÉΓòÉΓòÉ
  12011.  
  12012. HistWinEnd = Key (Ctrl-PgDn):  Moves to the last line of the history when in 
  12013. the history window. 
  12014.  
  12015.  
  12016. ΓòÉΓòÉΓòÉ 10.4.4.3.6. HistWinExec ΓòÉΓòÉΓòÉ
  12017.  
  12018. HistWinExec = Key (Enter):  Executes the selected line in the history window. 
  12019.  
  12020.  
  12021. ΓòÉΓòÉΓòÉ 10.4.4.3.7. HistWinOpen ΓòÉΓòÉΓòÉ
  12022.  
  12023. HistWinOpen = Key (Ctrl-PgUp):  Brings up the history window while at the 
  12024. command line.  Also see Scrolling and History Keystrokes and the SwapScrollKeys 
  12025. directive. 
  12026.  
  12027.  
  12028. ΓòÉΓòÉΓòÉ 10.4.4.3.8. NormalHWinKey ΓòÉΓòÉΓòÉ
  12029.  
  12030. NormalHWinKey = Key:  Deassigns a history window key in order to disable the 
  12031. usual meaning of the key within the history window. For additional details see 
  12032. NormalKey. 
  12033.  
  12034.  
  12035. ΓòÉΓòÉΓòÉ 10.4.4.4. LIST Keys ΓòÉΓòÉΓòÉ
  12036.  
  12037. These directives are effective only inside the LIST command.  The LIST keys 
  12038. are: 
  12039.  
  12040.         ListExit            Exits the current file 
  12041.         ListFind            Prompts and searches for a string 
  12042.         ListHex             Toggles hexadecimal display mode 
  12043.         ListHighBit         Toggles LIST's "strip high bit" option 
  12044.         ListInfo            Displays information about the current file 
  12045.         ListNext            Finds the next matching string 
  12046.         ListPrint           Prints the file on LPT1 
  12047.         ListWrap            Toggles LIST's wrap option 
  12048.         NormalListKey       Deassigns a LIST key 
  12049.  
  12050.  
  12051. ΓòÉΓòÉΓòÉ 10.4.4.4.1. ListExit ΓòÉΓòÉΓòÉ
  12052.  
  12053. ListExit = Key (Esc):  Exits the current file. 
  12054.  
  12055.  
  12056. ΓòÉΓòÉΓòÉ 10.4.4.4.2. ListFind ΓòÉΓòÉΓòÉ
  12057.  
  12058. ListFind = Key (F):  Prompts and searches for a string. 
  12059.  
  12060.  
  12061. ΓòÉΓòÉΓòÉ 10.4.4.4.3. ListHex ΓòÉΓòÉΓòÉ
  12062.  
  12063. ListHex = Key (X):  Toggles hexadecimal display mode. 
  12064.  
  12065.  
  12066. ΓòÉΓòÉΓòÉ 10.4.4.4.4. ListHighBit ΓòÉΓòÉΓòÉ
  12067.  
  12068. ListHighBit = Key (H):  Toggles LIST's "strip high bit" option, which can aid 
  12069. in displaying files from certain word processors. 
  12070.  
  12071.  
  12072. ΓòÉΓòÉΓòÉ 10.4.4.4.5. ListInfo ΓòÉΓòÉΓòÉ
  12073.  
  12074. ListInfo = Key (I):  Displays information about the current file. 
  12075.  
  12076.  
  12077. ΓòÉΓòÉΓòÉ 10.4.4.4.6. ListNext ΓòÉΓòÉΓòÉ
  12078.  
  12079. ListNext = Key (N):  Finds the next matching string. 
  12080.  
  12081.  
  12082. ΓòÉΓòÉΓòÉ 10.4.4.4.7. ListPrint ΓòÉΓòÉΓòÉ
  12083.  
  12084. ListPrint = Key (P):  Prints the file on the printer you select in the popup 
  12085. dialog, or through the default print queue. 
  12086.  
  12087.  
  12088. ΓòÉΓòÉΓòÉ 10.4.4.4.8. ListWrap ΓòÉΓòÉΓòÉ
  12089.  
  12090. ListWrap = Key (W):  Toggles LIST's wrap option on and off. The wrap option 
  12091. wraps text at the right margin. 
  12092.  
  12093.  
  12094. ΓòÉΓòÉΓòÉ 10.4.4.4.9. NormalListKey ΓòÉΓòÉΓòÉ
  12095.  
  12096. NormalListKey = Key:  Deassigns a LIST key in order to disable the usual 
  12097. meaning of the key within LIST.  For additional details see NormalKey. 
  12098.  
  12099.  
  12100. ΓòÉΓòÉΓòÉ 10.4.4.5. Scrollback Buffer Keys ΓòÉΓòÉΓòÉ
  12101.  
  12102. These directives control the keys used to manipulate the scrollback buffer. 
  12103. For additional information see Scrolling and History Keystrokes and the 
  12104. SwapScrollKeys directive.  The scrollback buffer keys are: 
  12105.  
  12106.         ScrollUp            Scroll the buffer up one line 
  12107.         ScrollDown          Scroll the buffer down one line 
  12108.         ScrollPgUp          Scroll the buffer up one page 
  12109.         ScrollPgDn          Scroll the buffer down one page 
  12110.  
  12111.  
  12112. ΓòÉΓòÉΓòÉ 10.4.4.5.1. ScrollUp ΓòÉΓòÉΓòÉ
  12113.  
  12114. ScrollUp = Key (Up):  Scrolls the Take Command scrollback buffer up one line. 
  12115.  
  12116.  
  12117. ΓòÉΓòÉΓòÉ 10.4.4.5.2. ScrollDown ΓòÉΓòÉΓòÉ
  12118.  
  12119. ScrollDown = Key (Down):  Scrolls the Take Command scrollback buffer down one 
  12120. line. 
  12121.  
  12122.  
  12123. ΓòÉΓòÉΓòÉ 10.4.4.5.3. ScrollPageUp ΓòÉΓòÉΓòÉ
  12124.  
  12125. ScrollPgUp = Key (PgUp):  Scrolls the Take Command scrollback buffer up one 
  12126. page. 
  12127.  
  12128.  
  12129. ΓòÉΓòÉΓòÉ 10.4.4.5.4. ScrollPageDown ΓòÉΓòÉΓòÉ
  12130.  
  12131. ScrollPgDn = Key (PgDn):  Scrolls the Take Command scrollback buffer down one 
  12132. page. 
  12133.  
  12134.  
  12135. ΓòÉΓòÉΓòÉ 10.4.5. Advanced Directives ΓòÉΓòÉΓòÉ
  12136.  
  12137. These directives are generally used for unusual circumstances, or for 
  12138. diagnosing problems. Most often they are not needed in normal use.  They cannot 
  12139. be entered via the configuration notebook; you must enter them manually (see 
  12140. TCMDOS2.INI for details). 
  12141.  
  12142. The only advanced directive available at this time is: 
  12143.  
  12144.         ClearKeyMap         Clear default key mappings 
  12145.  
  12146.  
  12147. ΓòÉΓòÉΓòÉ 10.4.5.1. ClearKeyMap ΓòÉΓòÉΓòÉ
  12148.  
  12149. ClearKeyMap:  Clears all current key mappings. ClearKeyMap is a special 
  12150. directive which has no value or "=" after it.  Use ClearKeyMap to make one of 
  12151. the keys in the default map (Tab, Shift-Tab, Ctrl-Tab, or Ctrl-Bksp) available 
  12152. for a keystroke alias.  ClearKeyMap should appear before any other key mapping 
  12153. directives.  If you want to clear some but not all of the default mappings, use 
  12154. ClearKeyMap, then recreate the mappings you want to retain (e.g., with 
  12155. "NextFile=Tab", etc.). 
  12156.  
  12157.  
  12158. ΓòÉΓòÉΓòÉ 11. Error Messages ΓòÉΓòÉΓòÉ
  12159.  
  12160. This section lists error messages generated by Take Command, and includes a 
  12161. recommended course of action for most errors.  If you are unable to resolve the 
  12162. problem, look through your Introduction and Installation Guide for any 
  12163. additional troubleshooting recommendations, then contact JP Software for 
  12164. technical support. 
  12165.  
  12166. Error messages relating to files are generally reports of errors returned by 
  12167. OS/2.  You may find some of these messages (for example, "Access denied") vague 
  12168. enough that they are not always helpful.  Take Command includes the file name 
  12169. in file error messages, but is often unable to determine a more accurate 
  12170. explanation of these errors.  The message shown is the best information 
  12171. available based on the error codes returned by OS/2. 
  12172.  
  12173. The following list includes all error messages, in alphabetical order: 
  12174.  
  12175. Access denied:  You tried to write to or erase a read-only file, rename a file 
  12176. or directory to an existing name, create a directory that already exists, 
  12177. remove a read-only directory or a directory with files or subdirectories still 
  12178. in it, or access a file in use by another program. 
  12179.  
  12180. Alias loop:  An alias refers back to itself either directly or indirectly 
  12181. (i.e., a = b = a), or aliases are nested more than 16 deep.  Correct your alias 
  12182. list. 
  12183.  
  12184. Bad disk unit:  Generally caused by a disk drive hardware failure. 
  12185.  
  12186. Batch file missing:  Take Command can't find the batch (.BTM or .CMD) file it 
  12187. was running. It was either deleted, renamed, moved, or the disk was changed. 
  12188. Correct the problem and rerun the file. 
  12189.  
  12190. Can't COPY or MOVE file to itself:  You cannot COPY or MOVE a file to itself. 
  12191. Take Command performs full path and filename expansion before copying to ensure 
  12192. that files aren't inadvertently destroyed. 
  12193.  
  12194. Can't create:  Take Command can't create the specified file.  The disk may be 
  12195. full or write protected, or the file already exists and is read-only, or the 
  12196. root directory is full. 
  12197.  
  12198. Can't delete:  Take Command can't delete the specified file or directory.  The 
  12199. disk is probably write protected. 
  12200.  
  12201. Can't get directory:  Take Command can't read the directory.  The disk drive is 
  12202. probably not ready. 
  12203.  
  12204. Can't make directory entry:  Take Command can't create the filename in the 
  12205. directory.  This is usually caused by a full root directory. Create a 
  12206. subdirectory and move some of the files to it. 
  12207.  
  12208. Can't open:  Take Command can't open the specified file. Either the file 
  12209. doesn't exist or the disk directory or File Allocation Table is damaged. 
  12210.  
  12211. Can't remove current directory:  You attempted to remove the current directory, 
  12212. which OS/2 does not allow.  Change to the parent directory and try again. 
  12213.  
  12214. Command line too long:  A single command exceeded 1023 characters, or the 
  12215. entire command line exceeded 2047 characters, during alias and variable 
  12216. expansion.  Reduce the complexity of the command or use a batch file.  Also 
  12217. check for an alias which refers back to itself either directly or indirectly. 
  12218.  
  12219. Command only valid in batch file:  You have tried to use a batch file command, 
  12220. like DO or GOSUB, from the command line or in an alias.  A few commands can 
  12221. only be used in batch files (see the individual commands for details). 
  12222.  
  12223. Contents lost before copy:  COPY was appending files, and found one of the 
  12224. source files is the same as the target.  That source file is skipped, and 
  12225. appending continues with the next file. 
  12226.  
  12227. Data error:  OS/2 can't read or write properly to the device. On a floppy 
  12228. drive, this error is usually caused by a defective floppy disk, dirty disk 
  12229. drive heads, or a misalignment between the heads on your drive and the drive on 
  12230. which the disk was created. On a hard drive, this error may indicate a drive 
  12231. that is too hot or too cold, or a hardware problem.  Retry the operation; if it 
  12232. fails again, correct the hardware or diskette problem. 
  12233.  
  12234. Directory stack empty:  POPD or DIRS can't find any entries in the directory 
  12235. stack. 
  12236.  
  12237. Disk is write protected:  The disk cannot be written to. Check the disk and 
  12238. remove the write-protect tab or close the write- protect window if necessary. 
  12239.  
  12240. Drive not ready -- close door:  The floppy disk drive door is open.  Close the 
  12241. door and try again. 
  12242.  
  12243. Environment already saved:  You have already saved the environment with a 
  12244. previous SETLOCAL command.  You cannot nest SETLOCAL / ENDLOCAL pairs. 
  12245.  
  12246. Error in command-line directive:  You used the //iniline option to place an 
  12247. .INI directive on the startup command line, but the directive is in error.  A 
  12248. more specific error message follows. 
  12249.  
  12250. Error on line [nnnn] of [filename]:  There is an error in your TCMDOS2.INI 
  12251. file. The following message explains the error in more detail.  Correct the 
  12252. line in error and restart Take Command for your change to take effect. 
  12253.  
  12254. Error reading:  OS/2 experienced an I/O error when reading from a device.  This 
  12255. is usually caused by a bad disk, a device not ready, or a hardware error. 
  12256.  
  12257. Error writing:  OS/2 experienced an I/O error when writing to a device.  This 
  12258. is usually caused by a full disk, a bad disk, a device not ready, or a hardware 
  12259. error. 
  12260.  
  12261. Exceeded batch nesting limit:  You have attempted to nest batch files more than 
  12262. 10 levels deep. 
  12263.  
  12264. File Allocation Table bad:  OS/2 can't access the FAT on the specified disk. 
  12265. This can be caused by a bad disk, a hardware error, or an unusual software 
  12266. interaction. 
  12267.  
  12268. File exists:  The requested output file already exists, and Take Command won't 
  12269. overwrite it. 
  12270.  
  12271. File not found:  Take Command couldn't find the specified file.  Check the 
  12272. spelling and path name. 
  12273.  
  12274. General failure:  This is usually a hardware problem, particularly a disk drive 
  12275. failure or a device not properly connected to a serial or parallel port.  Try 
  12276. to correct the problem, or reboot and try again.  Also see Data error above; 
  12277. the problems described there can sometimes cause a general failure rather than 
  12278. a data error. 
  12279.  
  12280. Infinite COPY or MOVE loop:  You tried to COPY or MOVE a directory to one of 
  12281. its own subdirectories and used the /S switch, so the command would run 
  12282. forever.  Correct the command and try again. 
  12283.  
  12284. Insufficient disk space:  COPY or MOVE ran out of room on the destination 
  12285. drive.  Remove some files and retry the operation. 
  12286.  
  12287. Invalid character value:  You gave an invalid value for a character directive 
  12288. in the TCMDOS2.INI file. 
  12289.  
  12290. Invalid choice value:  You gave an invalid value for a "choice" directive (one 
  12291. that accepts a choice from a list, like "Yes" or "No") in the TCMDOS2.INI file. 
  12292.  
  12293. Invalid color:  You gave an invalid value for a color directive in the 
  12294. TCMDOS2.INI file. 
  12295.  
  12296. Invalid date:  An invalid date was entered.  Check the syntax and reenter. 
  12297.  
  12298. Invalid directive name:  Take Command can't recognize the name of a directive 
  12299. in your TCMDOS2.INI file. 
  12300.  
  12301. Invalid drive:  A bad or non-existent disk drive was specified. 
  12302.  
  12303. Invalid key name:  You tried to make an invalid key substitution in the 
  12304. TCMDOS2.INI file, or you used an invalid key name in a keystroke alias or 
  12305. command.  Correct the error and retry the operation. 
  12306.  
  12307. Invalid numeric value:  You gave an invalid value for a numeric directive in 
  12308. the TCMDOS2.INI file. 
  12309.  
  12310. Invalid parameter:  Take Command didn't recognize a parameter.  Check the 
  12311. syntax and spelling of the command you entered. 
  12312.  
  12313. Invalid path:  The specified path does not exist. Check the disk specification 
  12314. and/or spelling. 
  12315.  
  12316. Invalid path or file name:  You used an invalid path or filename in a directive 
  12317. in the TCMDOS2.INI file. 
  12318.  
  12319. Invalid time:  An invalid time was entered.  Check the syntax and reenter. 
  12320.  
  12321. Keystroke substitution table full:  Take Command ran out of room to store 
  12322. keystroke substitutions entered in the TCMDOS2.INI file.  Reduce the number of 
  12323. key substitutions or contact JP Software for assistance. 
  12324.  
  12325. Label not found:  A GOTO or GOSUB referred to a non-existent label. Check your 
  12326. batch file. 
  12327.  
  12328. Missing ENDTEXT:  A TEXT command is missing a matching ENDTEXT.  Check the 
  12329. batch file. 
  12330.  
  12331. Missing GOSUB:  Take Command cannot perform the RETURN command in a batch file. 
  12332. You tried to do a RETURN without a GOSUB, or your batch file has been 
  12333. corrupted. 
  12334.  
  12335. Missing SETLOCAL:  An ENDLOCAL was used without a matching SETLOCAL. 
  12336.  
  12337. No aliases defined:  You tried to display aliases but no aliases have been 
  12338. defined. 
  12339.  
  12340. No closing quote:  Take Command couldn't find a second matching back quote [`] 
  12341. or double-quote ["] on the command line. 
  12342.  
  12343. No expression:  The expression passed to the %@EVAL variable function is empty. 
  12344. Correct the expression and retry the operation. 
  12345.  
  12346. No shared memory found:  The SHRALIAS command could not find any global alias 
  12347. list, history list, or directory history list to retain, because you executed 
  12348. the command from a session with local lists.  Start Take Command with at least 
  12349. one global list, then invoke SHRALIAS. 
  12350.  
  12351. Not an alias:  The specified alias is not in the alias list. 
  12352.  
  12353. Not in environment:  The specified variable is not in the environment. 
  12354.  
  12355. Not ready:  The specified device can't be accessed. 
  12356.  
  12357. Not same device:  This error usually appears in RENAME. You cannot rename a 
  12358. file to a different disk drive. 
  12359.  
  12360. Out of memory:  Take Command or OS/2 had insufficient memory to execute the 
  12361. last command.  Try to free some memory by closing other sessions.  If the error 
  12362. persists, contact JP Software for assistance. 
  12363.  
  12364. Out of paper:  OS/2 detected an out-of-paper condition on one of the printers 
  12365. (LPT1, LPT2, or LPT3).  Check your printer and add paper if necessary. 
  12366.  
  12367. Overflow:  An arithmetic overflow occurred in the %@EVAL variable function. 
  12368. Check the values being passed to %@EVAL. %@EVAL can handle 16 digits to the 
  12369. left of the decimal point and 8 to the right. 
  12370.  
  12371. Read error:  OS/2 encountered a disk read error; usually caused by a bad or 
  12372. unformatted disk. 
  12373.  
  12374. Sector not found:  Disk error, usually caused by a bad or unformatted disk. 
  12375.  
  12376. Seek error:  OS/2 can't seek to the proper location on the disk.  This is 
  12377. generally caused by a bad disk or drive. 
  12378.  
  12379. SHRALIAS already loaded:  You used the SHRALIAS command to load SHRALIAS.EXE, 
  12380. but it was already loaded.  This message is informational and generally does 
  12381. not indicate an error condition. 
  12382.  
  12383. SHRALIAS not loaded:  You used the SHRALIAS /U command to unload SHRALIAS.EXE, 
  12384. but it was never loaded.  This message is informational and may not indicate an 
  12385. error condition. 
  12386.  
  12387. Sharing violation:  You tried to access a file in use by another program.  Wait 
  12388. for the file to become available, or change your method of operation so that 
  12389. another program does not have the file open while you are trying to use it. 
  12390.  
  12391. String area overflow:  Take Command ran out of room to store the text from 
  12392. string directives in the TCMDOS2.INI file.  Reduce the complexity of the 
  12393. TCMDOS2.INI file or contact JP Software for assistance. 
  12394.  
  12395. Syntax error:  A command or variable function was entered in an improper 
  12396. format.  Check the syntax and correct the error. 
  12397.  
  12398. Too many open files:  OS/2 has run out of file handles. 
  12399.  
  12400. Unbalanced parentheses:  The number of left and right parentheses did not match 
  12401. in an expression passed to the %@EVAL variable function.  Correct the 
  12402. expression and retry the operation. 
  12403.  
  12404. Unknown command:  A command was entered that Take Command didn't recognize and 
  12405. couldn't find in the current search path.  Check the spelling or PATH 
  12406. specification.  You can handle unknown commands with the UNKNOWN_CMD alias (see 
  12407. ALIAS). 
  12408.  
  12409. Variable loop:  A nested environment variable refers to itself, or variables 
  12410. are nested more than 16 deep.  Correct the error and retry the command. 
  12411.  
  12412. Write error:  OS/2 encountered a disk write error; usually caused by a bad or 
  12413. unformatted disk. 
  12414.  
  12415.  
  12416. ΓòÉΓòÉΓòÉ 12. Reference Tables ΓòÉΓòÉΓòÉ
  12417.  
  12418. The tables in this section are based on U.S. English conventions.  Your system 
  12419. may differ if it is configured for a different country or language.  See your 
  12420. operating system documentation for more information about country and language 
  12421. support. 
  12422.  
  12423. To represent the text you type, computers must translate each letter to and 
  12424. from a number.  The code used by all PC-compatible computers for this 
  12425. translation is called ASCII.  Function keys, cursor keys, and Alt keys generate 
  12426. scan codes indicating which key was pressed, but not ASCII codes.  The tables 
  12427. in this section cover both kinds of codes. 
  12428.  
  12429. For more information, see: 
  12430.  
  12431.             ASCII Table 
  12432.             Key Codes and Scan Codes Table 
  12433.             Key Codes and Scan Codes Explanation 
  12434.             ANSI Reference 
  12435.  
  12436.  
  12437. ΓòÉΓòÉΓòÉ 12.1. ASCII Table ΓòÉΓòÉΓòÉ
  12438.  
  12439.                       Control Characters
  12440.  
  12441.     Dec  Hex  Chr  Nam  Ctl   Γöé   Dec  Hex  Chr  Nam  Ctl
  12442.     ---  ---  ---  ---  ---   Γöé   ---  ---  ---  ---  ---
  12443.     000   00       NUL   ^@   Γöé   016   10      DLE   ^P
  12444.     001   01      SOH   ^A   Γöé   017   11      DC1   ^Q
  12445.     002   02      STX   ^B   Γöé   018   12      DC2   ^R
  12446.     003   03      ETX   ^C   Γöé   019   13      DC3   ^S
  12447.     004   04      EOT   ^D   Γöé   020   14      DC4   ^T
  12448.     005   05      ENQ   ^E   Γöé   021   15      NAK   ^U
  12449.     006   06      ACK   ^F   Γöé   022   16      SYN   ^V
  12450.     007   07       BEL   ^G   Γöé   023   17      ETB   ^W
  12451.     008   08      BS    ^H   Γöé   024   18      CAN   ^X
  12452.     009   09       HT    ^I   Γöé   025   19      EM    ^Y
  12453.     010   0A       LF    ^J   Γöé   026   1A      SUB   ^Z
  12454.     011   0B       VT    ^K   Γöé   027   1B      ESC   ^[
  12455.     012   0C       FF    ^L   Γöé   028   1C      FS    ^\
  12456.     013   0D       CR    ^M   Γöé   029   1D      GS    ^]
  12457.     014   0E      SO    ^N   Γöé   030   1E      RS    ^^
  12458.     015   0F      SI    ^O   Γöé   031   1F      US    ^_
  12459.  
  12460.                   Punctuation, Digits, Upper Case
  12461.  
  12462.   Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  12463.   ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  ---
  12464.   032   20      Γöé  048   30   0  Γöé  064   40   @  Γöé  080   50   P
  12465.   033   21   !  Γöé  049   31   1  Γöé  065   41   A  Γöé  081   51   Q
  12466.   034   22   "  Γöé  050   32   2  Γöé  066   42   B  Γöé  082   52   R
  12467.   035   23   #  Γöé  051   33   3  Γöé  067   43   C  Γöé  083   53   S
  12468.   036   24   $  Γöé  052   34   4  Γöé  068   44   D  Γöé  084   54   T
  12469.   037   25   %  Γöé  053   35   5  Γöé  069   45   E  Γöé  085   55   U
  12470.   038   26   &  Γöé  054   36   6  Γöé  070   46   F  Γöé  086   56   V
  12471.   039   27   '  Γöé  055   37   7  Γöé  071   47   G  Γöé  087   57   W
  12472.   040   28   (  Γöé  056   38   8  Γöé  072   48   H  Γöé  088   58   X
  12473.   041   29   )  Γöé  057   39   9  Γöé  073   49   I  Γöé  089   59   Y
  12474.   042   2A   *  Γöé  058   3A   :  Γöé  074   4A   J  Γöé  090   5A   Z
  12475.   043   2B   +  Γöé  059   3B   ;  Γöé  075   4B   K  Γöé  091   5B   [
  12476.   044   2C   ,  Γöé  060   3C   <  Γöé  076   4C   L  Γöé  092   5C   \
  12477.   045   2D   -  Γöé  061   3D   =  Γöé  077   4D   M  Γöé  093   5D   ]
  12478.   046   2E   .  Γöé  062   3E   >  Γöé  078   4E   N  Γöé  094   5E   ^
  12479.   047   2F   /  Γöé  063   3F   ?  Γöé  079   4F   O  Γöé  095   5F   _
  12480.  
  12481.                    Lower Case, Miscellaneous
  12482.  
  12483.                  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  12484.                  ---  ---  --- Γöé  ---  ---  ---
  12485.                  096   60   `  Γöé  112   70   p
  12486.                  097   61   a  Γöé  113   71   q
  12487.                  098   62   b  Γöé  114   72   r
  12488.                  099   63   c  Γöé  115   73   s
  12489.                  100   64   d  Γöé  116   74   t
  12490.                  101   65   e  Γöé  117   75   u
  12491.                  102   66   f  Γöé  118   76   v
  12492.                  103   67   g  Γöé  119   77   w
  12493.                  104   68   h  Γöé  120   78   x
  12494.                  105   69   i  Γöé  121   79   y
  12495.                  106   6A   j  Γöé  122   7A   z
  12496.                  107   6B   k  Γöé  123   7B   {
  12497.                  108   6C   l  Γöé  124   7C   |
  12498.                  109   6D   m  Γöé  125   7D   }
  12499.                  110   6E   n  Γöé  126   7E   ~
  12500.                  111   6F   o  Γöé  127   7F   
  12501.  
  12502.                 International; Graphics Characters 1
  12503.  
  12504.   Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  12505.   ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  ---
  12506.   128   80   ╨É  Γöé  144   90   ╨á  Γöé  160   A0   ╨░  Γöé  176   B0   Γûæ
  12507.   129   81   ╨æ  Γöé  145   91   ╨í  Γöé  161   A1   ╨▒  Γöé  177   B1   ΓûÆ
  12508.   130   82   ╨Æ  Γöé  146   92   ╨ó  Γöé  162   A2   ╨▓  Γöé  178   B2   Γûô
  12509.   131   83   ╨ô  Γöé  147   93   ╨ú  Γöé  163   A3   ╨│  Γöé  179   B3   Γöé
  12510.   132   84   ╨ö  Γöé  148   94   ╨ñ  Γöé  164   A4   ╨┤  Γöé  180   B4   Γöñ
  12511.   133   85   ╨ò  Γöé  149   95   ╨Ñ  Γöé  165   A5   ╨╡  Γöé  181   B5   Γòí
  12512.   134   86   ╨û  Γöé  150   96   ╨ª  Γöé  166   A6   ╨╢  Γöé  182   B6   Γòó
  12513.   135   87   ╨ù  Γöé  151   97   ╨º  Γöé  167   A7   ╨╖  Γöé  183   B7   Γòû
  12514.   136   88   ╨ÿ  Γöé  152   98   ╨¿  Γöé  168   A8   ╨╕  Γöé  184   B8   Γòò
  12515.   137   89   ╨Ö  Γöé  153   99   ╨⌐  Γöé  169   A9   ╨╣  Γöé  185   B9   Γòú
  12516.   138   8A   ╨Ü  Γöé  154   9A   ╨¬  Γöé  170   AA   ╨║  Γöé  186   BA   Γòæ
  12517.   139   8B   ╨¢  Γöé  155   9B   ╨½  Γöé  171   AB   ╨╗  Γöé  187   BB   Γòù
  12518.   140   8C   ╨£  Γöé  156   9C   ╨¼  Γöé  172   AC   ╨╝  Γöé  188   BC   Γò¥
  12519.   141   8D   ╨¥  Γöé  157   9D   ╨¡  Γöé  173   AD   ╨╜  Γöé  189   BD   Γò£
  12520.   142   8E   ╨₧  Γöé  158   9E   ╨«  Γöé  174   AE   ╨╛  Γöé  190   BE   Γò¢
  12521.   143   8F   ╨ƒ  Γöé  159   9F   ╨»  Γöé  175   AF   ╨┐  Γöé  191   BF   ΓöÉ
  12522.  
  12523.                   Graphics Characters 2; Symbols
  12524.  
  12525.   Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr Γöé  Dec  Hex  Chr
  12526.   ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  --- Γöé  ---  ---  ---
  12527.   192   C0   Γöö  Γöé  208   D0   Γò¿  Γöé  224   E0   ╤Ç  Γöé  240   F0   ╨ü
  12528.   193   C1   Γö┤  Γöé  209   D1   Γòñ  Γöé  225   E1   ╤ü  Γöé  241   F1   ╤æ
  12529.   194   C2   Γö¼  Γöé  210   D2   ΓòÑ  Γöé  226   E2   ╤é  Γöé  242   F2   ╨ä
  12530.   195   C3   Γö£  Γöé  211   D3   ΓòÖ  Γöé  227   E3   ╤â  Γöé  243   F3   ╤ö
  12531.   196   C4   ΓöÇ  Γöé  212   D4   Γòÿ  Γöé  228   E4   ╤ä  Γöé  244   F4   ╨ç
  12532.   197   C5   Γö╝  Γöé  213   D5   ΓòÆ  Γöé  229   E5   ╤à  Γöé  245   F5   ╤ù
  12533.   198   C6   Γò₧  Γöé  214   D6   Γòô  Γöé  230   E6   ╤å  Γöé  246   F6   ╨Ä
  12534.   199   C7   Γòƒ  Γöé  215   D7   Γò½  Γöé  231   E7   ╤ç  Γöé  247   F7   ╤₧
  12535.   200   C8   ΓòÜ  Γöé  216   D8   Γò¬  Γöé  232   E8   ╤ê  Γöé  248   F8   ┬░
  12536.   201   C9   Γòö  Γöé  217   D9   Γöÿ  Γöé  233   E9   ╤ë  Γöé  249   F9   ΓêÖ
  12537.   202   CA   Γò⌐  Γöé  218   DA   Γöî  Γöé  234   EA   ╤è  Γöé  250   FA   ┬╖
  12538.   203   CB   Γòª  Γöé  219   DB   Γûê  Γöé  235   EB   ╤ï  Γöé  251   FB   ΓêÜ
  12539.   204   CC   Γòá  Γöé  220   DC   Γûä  Γöé  236   EC   ╤î  Γöé  252   FC   Γäû
  12540.   205   CD   ΓòÉ  Γöé  221   DD   Γûî  Γöé  237   ED   ╤ì  Γöé  253   FD   ┬ñ
  12541.   206   CE   Γò¼  Γöé  222   DE   ΓûÉ  Γöé  238   EE   ╤Ä  Γöé  254   FE   Γûá
  12542.   207   CF   Γòº  Γöé  223   DF   ΓûÇ  Γöé  239   EF   ╤Å  Γöé  255   FF
  12543.  
  12544.  
  12545. ΓòÉΓòÉΓòÉ 12.2. Key Codes and Scan Codes Table ΓòÉΓòÉΓòÉ
  12546.  
  12547. (For more details on key codes and scan codes, see the Key Codes and Scan Codes 
  12548. Explanation.) 
  12549.  
  12550. Key names prefaced by np are on the numeric keypad.  Those prefaced by cp are 
  12551. on the cursor keypad between the main typing keys and the number keypad.  The 
  12552. numeric keypad values are valid if Num Lock is turned off.  If you need to 
  12553. specify a number key from the numeric keypad, use the scan code shown for the 
  12554. keypad and the ASCII code shown for the corresponding typewriter key.  For 
  12555. example, the keypad "7" has a scan code of 71 (the np Home scan code) and an 
  12556. ASCII code of 54 (the ASCII code for "7"). 
  12557.  
  12558. The chart is blank for key combinations that do not have scan codes or ASCII 
  12559. codes, like Ctrl-1 or Alt-PgUp. 
  12560.  
  12561.  
  12562.                         Top Two Keyboard Rows
  12563.  
  12564.                              Shift  Shift  Ctrl   Ctrl   Alt
  12565.                Scan   ASCII  Scan   ASCII  Scan   ASCII  Scan
  12566.      Key       Code   Code   Code   Code   Code   Code   Code
  12567.  
  12568.      Esc       1      27     1      27     1      27     1
  12569.      1  !      2      49     2      33                   120
  12570.      2  @      3      50     3      64     3      0      121
  12571.      3  #      4      51     4      35                   122
  12572.      4  $      5      52     5      36                   123
  12573.      5  %      6      53     6      37                   124
  12574.      6  ^      7      54     7      94     7      30     125
  12575.      7  &      8      55     8      38                   126
  12576.      8  *      9      56     9      42                   127
  12577.      9  (      10     57     10     40                   128
  12578.      0  )      11     48     11     41                   129
  12579.      -  _      12     45     12     95     12     31     130
  12580.      =  +      13     61     13     43                   131
  12581.      Backspace 14     8      14     8      14     127    14
  12582.      Tab       15     9      15     0      148    0      165
  12583.      Q         16     113    16     81     16     17     16
  12584.      W         17     119    17     87     17     23     17
  12585.      E         18     101    18     69     18     5      18
  12586.      R         19     114    19     82     19     18     19
  12587.      T         20     116    20     84     20     20     20
  12588.      Y         21     121    21     89     21     25     21
  12589.      U         22     117    22     85     22     21     22
  12590.      I         23     105    23     73     23     9      23
  12591.      O         24     111    24     79     24     15     24
  12592.      P         25     112    25     80     25     16     25
  12593.      [  {      26     91     26     123    26     27     26
  12594.      ]  }      27     93     27     125    27     29     27
  12595.      Enter     28     13     28     13     28     10     28
  12596.  
  12597.  
  12598.                        Bottom Two Keyboard Rows
  12599.  
  12600.                              Shift  Shift  Ctrl   Ctrl   Alt
  12601.                Scan   ASCII  Scan   ASCII  Scan   ASCII  Scan
  12602.      Key       Code   Code   Code   Code   Code   Code   Code
  12603.  
  12604.      A         30     97     30     65     30     1      30
  12605.      S         31     115    31     83     31     19     31
  12606.      D         32     100    32     68     32     4      32
  12607.      F         33     102    33     70     33     6      33
  12608.      G         34     103    34     71     34     7      34
  12609.      H         35     104    35     72     35     8      35
  12610.      J         36     106    36     74     36     10     36
  12611.      K         37     107    37     75     37     11     37
  12612.      L         38     108    38     76     38     12     38
  12613.      ; :       39     59     39     58                   39
  12614.      '  "      40     39     40     34                   40
  12615.      `  ~      41     96     41     126                  41
  12616.      \  |      43     92     43     124    43     28     43
  12617.      Z         44     122    44     90     44     26     44
  12618.      X         45     120    45     88     45     24     45
  12619.      C         46     99     46     67     46     3      46
  12620.      V         47     118    47     86     47     22     47
  12621.      B         48     98     48     66     48     2      48
  12622.      N         49     110    49     78     49     14     49
  12623.      M         50     109    50     77     50     13     50
  12624.      ,  <      51     44     51     60                   51
  12625.      .  >      52     46     52     62                   52
  12626.      /  ?      53     47     53     63                   53
  12627.      Space     57     32     57     32     57     32     57
  12628.  
  12629.  
  12630.                       Key Pads and Function Keys
  12631.  
  12632.                              Shift  Shift  Ctrl   Ctrl   Alt
  12633.                Scan   ASCII  Scan   ASCII  Scan   ASCII  Scan
  12634.      Key       Code   Code   Code   Code   Code   Code   Code
  12635.  
  12636.  
  12637.      F1        59     0      84     0      94     0      104
  12638.      F2        60     0      85     0      95     0      105
  12639.      F3        61     0      86     0      96     0      106
  12640.      F4        62     0      87     0      97     0      107
  12641.      F5        63     0      88     0      98     0      108
  12642.      F6        64     0      89     0      99     0      109
  12643.      F7        65     0      90     0      100    0      110
  12644.      F8        66     0      91     0      101    0      111
  12645.      F9        67     0      92     0      102    0      112
  12646.      F10       68     0      93     0      103    0      113
  12647.      F11       133    0      135    0      137    0      139
  12648.      F12       134    0      136    0      138    0      140
  12649.      np *      55     42     55     42     150    0      55
  12650.      np Home   71     0      71     55     119    0
  12651.      cp Home   71     224    71     224    119    224    151
  12652.      np Up     72     0      72     56     141    0
  12653.      cp Up     72     224    72     224    141    224    152
  12654.      np PgUp   73     0      73     57     132    0
  12655.      cp PgUp   73     224    73     224    132    224    153
  12656.      np Minus  74     45     74     45     142    0      74
  12657.      np Left   75     0      75     52     115    0
  12658.      cp Left   75     224    75     224    115    224    155
  12659.      np 5      76     0      76     53     143    0
  12660.      np Right  77     0      77     54     116    0
  12661.      cp Right  77     224    77     224    116    224    157
  12662.      np Plus   78     43     78     43     144    0      78
  12663.      np End    79     0      79     49     117    0
  12664.      cp End    79     224    79     224    117    224    159
  12665.      np Down   80     0      80     50     145    0
  12666.      cp Down   80     224    80     224    145    224    160
  12667.      np PgDn   81     0      81     51     118    0
  12668.      cp PgDn   81     224    81     224    118    224    161
  12669.      np Ins    82     0      82     48     146    0
  12670.      cp Ins    82     224    82     224    146    224    162
  12671.      np Del    83     0      83     46     147    0
  12672.      cp Del    83     224    83     224    147    224    163
  12673.      np /      224    47     224    47     149    0      164
  12674.      np Enter  224    13     224    13     224    10     166
  12675.  
  12676.  
  12677. ΓòÉΓòÉΓòÉ 12.3. Key Codes and Scan Codes Explanation ΓòÉΓòÉΓòÉ
  12678.  
  12679. Key Codes and Scan Codes Explanation 
  12680.  
  12681. (This section explains how key codes and scan codes work.  For a reference 
  12682. chart, see the Key Codes and Scan Codes Table.) 
  12683.  
  12684. When you press a single key or a key combination, OS/2 translates your 
  12685. keystroke into two numbers: a scan code, representing the actual key that was 
  12686. pressed, and an ASCII code, representing the ASCII value for that key.  OS/2 
  12687. returns these numbers the next time a program requests keyboard input.  This 
  12688. section explains how key codes work; for information on using them with Take 
  12689. Command see the TCMDOS2.INI file key mapping directives, keystroke aliases, and 
  12690. INKEY. 
  12691.  
  12692. Most Take Command commands that use the numeric key codes listed here also use 
  12693. key names, which are usually more convenient to use than the numeric codes. 
  12694. See Keys and Key Names for more information on key names. 
  12695.  
  12696. As PCs have evolved, the structure of keyboard codes has evolved somewhat 
  12697. haphazardly with them, resulting in a bewildering array of possible key codes. 
  12698. We'll give you a basic explanation of how key codes work. For a more in-depth 
  12699. discussion, refer to a BIOS or PC hardware reference manual. 
  12700.  
  12701. The nuances of how your keyboard behaves depends on the keyboard manufacturer, 
  12702. the computer manufacturer who provides the built-in BIOS, and your operating 
  12703. system.  As a result, we can't guarantee the accuracy of the information in the 
  12704. tables for every system, but the discussion and reference table should be 
  12705. accurate for most systems.  Our discussion is based on the 101-key "enhanced" 
  12706. keyboard commonly used on 286, 386, 486, and Pentium computers, but virtually 
  12707. all of it is applicable to the 84-key keyboards on older systems.  The primary 
  12708. difference is that older keyboards lack a separate cursor pad and only have 10 
  12709. function keys. 
  12710.  
  12711. All keys have a scan code, but not all have an ASCII code.  For example, 
  12712. function keys and cursor keys are not part of the ASCII character set and have 
  12713. no ASCII value, but they do have a scan code.  Some keys have more than one 
  12714. ASCII code.  The A, for example, has ASCII code 97 (lower case "a") if you 
  12715. press it by itself.  If you press it along with Shift, the ASCII code changes 
  12716. to 65 (upper case "A"). If you press Ctrl and A the ASCII code changes to 1. In 
  12717. all these cases, the scan code (30) is unchanged because you are pressing the 
  12718. same physical key. 
  12719.  
  12720. Things are different if you press Alt-A.  Alt keystrokes have no ASCII code, so 
  12721. OS/2 returns an ASCII code of 0, along with the A key's scan code of 30.  This 
  12722. allows a program to detect all the possible variations of A, based on the 
  12723. combination of ASCII code and scan code. 
  12724.  
  12725. Some keys generate more than one scan code depending on whether Shift, Ctrl, or 
  12726. Alt is pressed.  This allows a program to differentiate between two different 
  12727. keystrokes on the same key, neither of which has a corresponding ASCII value. 
  12728. For example, F1 has no ASCII value so it returns an ASCII code of 0, and the F1 
  12729. scan code of 59.  Shift-F1 also returns an ASCII code 0; if it also returned a 
  12730. scan code of 59, a program couldn't distinguish it from F1.  The operating 
  12731. system translates scan codes for keys like Shift-F1 (and Ctrl-F1 and Alt-F1) so 
  12732. that each variation returns a different scan code along with an ASCII code of 
  12733. 0. 
  12734.  
  12735. On the 101-key keyboard there's one more variation:  non-ASCII keys on the 
  12736. cursor keypad (such as up-arrow) return the same scan code as the corresponding 
  12737. key on the numeric keypad, for compatibility reasons.  If they also returned an 
  12738. ASCII code of 0, a program couldn't tell which key was pressed.  Therefore, 
  12739. these keys return an ASCII code of 224 rather than 0.  This means that older 
  12740. programs, which only look for an ASCII 0 to indicate a non-ASCII keystroke like 
  12741. up-arrow, may not detect these cursor pad keys properly. 
  12742.  
  12743. The number of different codes returned by any given key varies from one (for 
  12744. the spacebar) to four, depending on the key, the design of your keyboard, and 
  12745. the operating system.  Some keys, like Alt, Ctrl, and Shift by themselves or in 
  12746. combination with each other, plus Print Screen, SysReq, Scroll Lock, Pause, 
  12747. Break, Num Lock, and Caps Lock keys, do not have any code representations at 
  12748. all.  The same is true of keystrokes with more than one modifying key, like 
  12749. Ctrl-Shift-A. The operating system may perform special actions automatically 
  12750. when you press these keys (for example, it switches into Caps Lock mode when 
  12751. you press Caps Lock), but it does not report the keystrokes to whatever program 
  12752. is running.  Programs which detect such keystrokes access the keyboard hardware 
  12753. directly, a subject which is beyond the scope of this manual. 
  12754.  
  12755.  
  12756. ΓòÉΓòÉΓòÉ 12.4. ANSI Reference ΓòÉΓòÉΓòÉ
  12757.  
  12758. Take Command for OS/2's ANSI support allows you to manipulate the cursor, 
  12759. screen color, and other display attributes through sequences of special 
  12760. characters embedded in the text you display on the screen.  These sequences are 
  12761. called "ANSI commands". 
  12762.  
  12763. This section is a quick-reference to the ANSI commands supported by Take 
  12764. Command for OS/2.  These sequences are typically displayed by internal 
  12765. commands, or by character-mode applications started under Take Command's TTY 
  12766. application support (see Starting Character-Mode Applications). 
  12767.  
  12768. ANSI support within Take Command for OS/2 can be enabled or disabled with the 
  12769. ANSI directive in TCMDOS2.INI, the corresponding option on the Display page of 
  12770. the configuration notebook, or the SETDOS /A command.  You can test whether 
  12771. ANSI support is enabled with the _ANSI internal variable. 
  12772.  
  12773. An ANSI command string consists of three parts: 
  12774.  
  12775.         ESC[                The ASCII character ESC, followed by a left 
  12776.                             bracket.  These two characters must be present in 
  12777.                             all ANSI strings. 
  12778.         parameters          Optional parameters for the command.  If there are 
  12779.                             multiple parameters they are separated by 
  12780.                             semicolons. 
  12781.         cmd                 A single-letter command.  The case of the letter IS 
  12782.                             meaningful. 
  12783.  
  12784.  For example, to position the cursor to row 7, column 12 the ANSI command is: 
  12785.  
  12786.           ESC[7;12H
  12787.  
  12788.  To transmit ANSI commands to the screen with Take Command for OS/2, you can 
  12789.  use the ECHO command.  The ESC character can be generated by inserting it into 
  12790.  the string directly (if you are putting the string in a batch file and your 
  12791.  editor will insert such a character), or by using Take command's internal 
  12792.  "escape" character (caret, [^]) followed by a lower-case "e".  For example, 
  12793.  the sequence shown above could be transmitted from a batch file with either of 
  12794.  these commands (the first uses an ESC character directly; the second uses ^e): 
  12795.  
  12796.           echo 2H
  12797.           echo ^e[7;12H
  12798.  
  12799.  You can also include ANSI commands in your prompt, using $e to transmit the 
  12800.  ESC character.  You can NOT use PROMPT to transmit ANSI commands to the screen 
  12801.  from a batch file (see PROMPT). 
  12802.  
  12803.  Commands 
  12804.  
  12805.         ESC[rowsA               Cursor up 
  12806.         ESC[rowsB               Cursor down 
  12807.         ESC[colsC               Cursor right 
  12808.         ESC[colsD               Cursor left 
  12809.         ESC[row;colH            Set cursor position (top left is row 1, column 
  12810.                                 1) 
  12811.         ESC[2J                  Clear screen 
  12812.         ESC[K                   Clear from cursor to end of line 
  12813.         ESC[row;colf            Set cursor position, same as "H" command 
  12814.         ESC[attr;attr;...m      Set display attributes; see table of attribute 
  12815.                                 values below 
  12816.         ESC[s                   Save cursor position (may not be nested) 
  12817.         ESC[u                   Restore cursor position after a save 
  12818.  
  12819.  Display Attributes 
  12820.  
  12821.         1           High intensity (bright) foreground color 
  12822.         2           Normal intensity 
  12823.         30-37       Set the foreground color: 
  12824.                       30=Black  31=Red    32=Green  33=Yellow 
  12825.                       34=Blue   35=Magenta  36=Cyan   37=White 
  12826.         40-47       Set the background color, same values as above but 
  12827.                     substitute 40 for 30 etc. 
  12828.  
  12829.  Settings are cumulative, so (for example) to set bright red foreground you 
  12830.  must first set red, then set high intensity: 
  12831.  
  12832.           echo ^e[31;1m
  12833.  
  12834.  Examples 
  12835.  
  12836.  Set the display to bright cyan on blue, and clear the screen: 
  12837.  
  12838.           echo ^e[44;36;1m^e[2J
  12839.  
  12840.  Set up a prompt which saves the cursor position, displays the date and time on 
  12841.  the top line in bright white on magenta, and then restores the cursor position 
  12842.  and sets the color to bright cyan on blue, and displays the standard prompt: 
  12843.  
  12844.           prompt $e[s$e[1;1f$e[45;37;1m$e[K$d $t$e[u$e[44;36;1m$p$g
  12845.  
  12846.  
  12847. ΓòÉΓòÉΓòÉ 13. Support ΓòÉΓòÉΓòÉ
  12848.  
  12849. You can contact JP Software at any of the following addresses.  Our normal 
  12850. business hours are 9:00 AM to 5:00 PM weekdays, Eastern US time. 
  12851.  
  12852. By mail: 
  12853.  
  12854.         JP Software Inc. 
  12855.         P.O. Box 1470 
  12856.         East Arlington, MA 02174 
  12857.         USA 
  12858.  
  12859.  By telephone / fax: 
  12860.  
  12861.         Voice           (617) 646-3975 
  12862.         Fax             (617) 646-0904 
  12863.         Order Line      (800) 368-8777 (orders only, USA only) 
  12864.  
  12865.  Electronically: 
  12866.  
  12867.         CompuServe      Sales / Customer Service:  75020,244 
  12868.                         Technical Support:  GO JPSOFT or GO PCVENB (section 
  12869.                         10), User ID 75300,1215 
  12870.  
  12871.         Internet        Sales / Customer Service:  sales@jpsoft.com 
  12872.                         Technical Support:  support@jpsoft.com 
  12873.  
  12874.         BBS Support     Via Channel 1 BBS, Boston, 617-354-3230 at 2,400 - 
  12875.                         14,400 baud; 617-349-1300 at 28,800 baud; no parity, 8 
  12876.                         data bits, 1 stop bit. 
  12877.  
  12878.  Technical support is available via public electronic support conferences, 
  12879.  private electronic mail, telephone, fax, and mail. 
  12880.  
  12881.  Often the best way to contact us for support is in one of the following public 
  12882.  electronic support conferences.  The numbers in parentheses indicate the usual 
  12883.  delay, in business days, to receive a reply to a message. 
  12884.  
  12885.  CompuServe / ZiffNet:  Primary support is via the JP Software section of the 
  12886.  CompuServe PCVENB forum (GO JPSOFT or GO PCVENB, section 10, "JP Software") (1 
  12887.  day). 
  12888.  
  12889.  Bulletin Boards:  Primary support is via the Channel 1 BBS, Boston, MA (1 - 3 
  12890.  days; see above for access details).  Messages may be left in any of the 
  12891.  "4DOS" conferences; check the online list for exact conference numbers. 
  12892.  Support is also available from many local BBSes via the "4DOS" conferences on 
  12893.  the RIME, ILink, and FidoNet BBS Networks (3-5 days). 
  12894.  
  12895.  Before contacting us for support, please check the manuals and other 
  12896.  documentation for answers to your question.  If you can't find what you need, 
  12897.  try the Index.  If you're having trouble getting Take Command for OS/2 to run 
  12898.  properly, either alone or with your particular hardware or software, see the 
  12899.  Introduction and Installation Guide, and the APPNOTES.DOC file.  Also look 
  12900.  through the README.DOC and UPDATxxx.DOC files, as they may contain updates to 
  12901.  the manual or other important information ("xxx" is the version number). 
  12902.  
  12903.  If you do need to contact us for support, it helps if you can give us some 
  12904.  basic information: 
  12905.  
  12906.     *   What exactly did you do?  A concise description of what steps you must 
  12907.         take to make the problem appear is much more useful than a long 
  12908.         analysis of what might be happening. 
  12909.  
  12910.     *   What went wrong?  At what point did the failure occur?  If you saw an 
  12911.         error message or other important or unusual information on the screen, 
  12912.         what exactly did it say? 
  12913.  
  12914.     *   Briefly, what techniques did you use to try to resolve the problem? 
  12915.         What results did you get? 
  12916.  
  12917.     *   What computer and operating system version are you using? 
  12918.  
  12919.     *   Are you running a network?  If so, which one, and which version? 
  12920.  
  12921.     *   What are the contents of any startup files you use (such as CONFIG.SYS, 
  12922.         4TCTART, TCEXIT, and TCMDOS2.INI ), any batch files they call, and any 
  12923.         alias or environment variable files they load? 
  12924.  
  12925.     *   Can you repeat the problem or does it occur randomly?  If it's random, 
  12926.         does it seem related to the programs you're using when the problem 
  12927.         occurs? 
  12928.